Account confirmers, Anti-spam team, Confirmed users, Bureaucrats and Sysops emeriti
4,925
edits
m (→QA team) |
(Update to reference Github) |
||
(17 intermediate revisions by one other user not shown) | |||
Line 2: | Line 2: | ||
The QA team was created on July 11, 2005, two days after the release of Bugzilla 2.18.3, to improve the quality of future releases. [http://www.bugzilla.org/releases/2.20/ Bugzilla 2.20], which was released two months later, became our most stable version ever released, with many security bugs fixed. This result has been possible partly thanks to the hard work done by the QA team which found several tens of bugs. But all the testing has been done manually, which required both a lot of time and a lot of people (the QA team had less than 10 members) to test the most important features of Bugzilla. | The QA team was created on July 11, 2005, two days after the release of Bugzilla 2.18.3, to improve the quality of future releases. [http://www.bugzilla.org/releases/2.20/ Bugzilla 2.20], which was released two months later, became our most stable version ever released, with many security bugs fixed. This result has been possible partly thanks to the hard work done by the QA team which found several tens of bugs. But all the testing has been done manually, which required both a lot of time and a lot of people (the QA team had less than 10 members) to test the most important features of Bugzilla. | ||
As repeating the same tests manually again and again for each new release quickly became boring, we decided to automate the process as much as possible using [http://seleniumhq.org/ Selenium]. | As repeating the same tests manually again and again for each new release quickly became boring, we decided to automate the process as much as possible using [http://seleniumhq.org/ Selenium]. The QA team uses [https://git.mozilla.org/?p=bugzilla/bugzilla.git;a=tree;f=xt;hb=HEAD Perl Selenium scripts]. | ||
== How to contribute? == | == How to contribute? == | ||
As Selenium cannot do everything, and because someone has to write these scripts anyway, we are always looking for new testers. If you are interested in helping us making Bugzilla better and more stable, feel free to join us. The best way to start is to join us in the [irc://irc.mozilla.org/ | As Selenium cannot do everything, and because someone has to write these scripts anyway, we are always looking for new testers. If you are interested in helping us making Bugzilla better and more stable, feel free to join us. The best way to start is to join us in the [irc://irc.mozilla.org/bugzilla #bugzilla] channel on IRC telling us that you are interested in contributing. Of course, you can also report bugs you discover to [https://bugzilla.mozilla.org/enter_bug.cgi?product=Bugzilla b.m.o] directly. If you want to help with automated tests, you are highly encouraged to read below, and download our existing test scripts. | ||
== Running Selenium scripts == | == Running Selenium scripts == | ||
A read-only copy of the current Selenium scripts can be downloaded using git: | |||
git clone https://github.com/bugzilla/bugzilla.git | |||
A read-only copy of the current Selenium scripts can be downloaded using | |||
A read/write copy can also be downloaded: | |||
git clone git@github.com:bugzilla/bugzilla.git | |||
A script named <em>xt/config/generate_test_data.pl</em> will automatically populate new installations, allowing the Selenium and WebService tests to be executed. | |||
'''Note 1:''' The Bugzilla installation to test must already exist, and must already have its important parameters configured (i.e. ''urlbase'', ''cookiepath'', and ''mail_delivery_method''). It is recommended that ''mail_delivery_method'' be set to '''Test''', unless "actual" bug mail is desired. | '''Note 1:''' The Bugzilla installation to test must already exist, and must already have its important parameters configured (i.e. ''urlbase'', ''cookiepath'', and ''mail_delivery_method''). It is recommended that ''mail_delivery_method'' be set to '''Test''', unless "actual" bug mail is desired. | ||
'''Note 2:''' Before executing <em>generate_test_data.pl</em>, make sure the parameters in <em>config/selenium_test.conf</em> are set correctly. This configuration file must match the Bugzilla configuration, especially the ''urlbase'' parameter and the path to the browser | '''Note 2:''' Before executing <em>generate_test_data.pl</em>, make sure the parameters in <em>xt/config/selenium_test.conf</em> are set correctly. This configuration file must match the Bugzilla configuration, especially the ''urlbase'' parameter and the path to the browser. If ''mail_delivery_method'' is set to '''Test''', fake user accounts can be defined in the config file. | ||
Once the DB is populated, start the Selenium server and execute the scripts in | Once the DB is populated, start the Selenium server and execute the scripts in xt/selenium. To start the Selenium server, type: | ||
java -jar /path/to/selenium-server.jar | java -jar /path/to/selenium-server-standalone-2.x.x.jar | ||
The Selenium Server can be downloaded from the [http://seleniumhq.org/download/ Selenium] website. To execute the scripts, go into the t/ directory and enter: | |||
prove -v --timer *.t | prove -v --timer *.t | ||
Line 36: | Line 29: | ||
== Writing Selenium scripts == | == Writing Selenium scripts == | ||
The fastest way to write new Selenium scripts is to use the [http://seleniumhq.org/download/ Selenium IDE] extension for Firefox. It records all your actions and converts them into a valid Selenium script. You can also write Selenium scripts manually with a text editor, but this is longer and can be pretty painful. | The fastest way to write new Selenium scripts is to use the [http://seleniumhq.org/download/ Selenium IDE] extension for Firefox (note that [http://release.seleniumhq.org/selenium-ide/1.0.12/selenium-ide-1.0.12.xpi Selenium IDE 1.0.12] is the last version to export Selenium scripts to the Perl language! Starting with version 1.1.0, the Perl exporter is no longer available). It records all your actions and converts them into a valid Selenium script. You can also write Selenium scripts manually with a text editor, but this is longer and can be pretty painful. | ||
Each command is of the form $sel->command_name_ok('field', 'value', 'description'), where $sel is the test object created by Test::WWW::Selenium. The description is optional, but may give some useful information. All available commands are listed [http://search.cpan.org/~ | Each command is of the form $sel->command_name_ok('field', 'value', 'description'), where $sel is the test object created by Test::WWW::Selenium. The description is optional, but may give some useful information. All available commands are listed [http://search.cpan.org/~mattp/Test-WWW-Selenium/lib/WWW/Selenium.pm here], and are fully documented. | ||
There are [https://bugzilla.mozilla.org/buglist.cgi?quicksearch=FIXED+testcase%3F many bugs] which need a test. You can pick one of them and write a test, either by improving one of the existing tests, or by writing a completely new one. There are also some other [https://bugzilla.mozilla.org/buglist.cgi?quicksearch=prod%3ABugzilla+comp%3AQA existing scripts] which need improvements. If you want to submit a script, please file it [https://bugzilla.mozilla.org/enter_bug.cgi?product=Bugzilla&component=QA%20Test%20Scripts here]. | |||