Test framework: Difference between revisions
(New page: Thunderforce's test framework uses XULRunner for both unit and integration testing. ==Test Architecture - Deployment View== ==Running Tests== ==Adding Tests==) |
No edit summary |
||
Line 2: | Line 2: | ||
==Test Architecture - Deployment View== | ==Test Architecture - Deployment View== | ||
The Thunderforce test framework exists as a Thunderbird extension in the [https://www.moonlightdesign.org/thunderforce/svn/trunk/tests/ tests folder in Subversion]. Within that folder, test suites exist in the [https://www.moonlightdesign.org/thunderforce/svn/trunk/tests/content/ content subfolder] with a file name that equals the name of the [https://www.moonlightdesign.org/thunderforce/svn/trunk/extension/components/ XPCOM component] that the test suite tests. Each test suite is included in the test framework by being included as a <script/> line in [https://www.moonlightdesign.org/thunderforce/svn/trunk/tests/content/testrunner.xul testrunner.xul]. | |||
==Running Tests== | ==Running Tests== | ||
To run tests, [[Getting Started - Developer#Eclipse configurations for running and debugging Thunderforce|create the Eclipse run configurations for tests]] and then run those. Those configurations use the "-thunderforceTest Label" command line option in the Thunderforce testing extension to run basic, normal, extra, or all tests. By default, running with the -thunderforceTest option prevents Thunderbird's main user interface from being displayed, but it's possible to force Thunderbird to show with the -thunderforceRunThunderbird command line option. The [https://www.moonlightdesign.org/thunderforce/svn/trunk/tests/components/nsThunderforceTestCommandLine.js nsThunderforceTestCommandLine.js] file handles the command line options for Thunderforce testing. | |||
== | ==Creating Tests== | ||
'''being written...''' |
Revision as of 21:12, 12 August 2007
Thunderforce's test framework uses XULRunner for both unit and integration testing.
Test Architecture - Deployment View
The Thunderforce test framework exists as a Thunderbird extension in the tests folder in Subversion. Within that folder, test suites exist in the content subfolder with a file name that equals the name of the XPCOM component that the test suite tests. Each test suite is included in the test framework by being included as a <script/> line in testrunner.xul.
Running Tests
To run tests, create the Eclipse run configurations for tests and then run those. Those configurations use the "-thunderforceTest Label" command line option in the Thunderforce testing extension to run basic, normal, extra, or all tests. By default, running with the -thunderforceTest option prevents Thunderbird's main user interface from being displayed, but it's possible to force Thunderbird to show with the -thunderforceRunThunderbird command line option. The nsThunderforceTestCommandLine.js file handles the command line options for Thunderforce testing.
Creating Tests
being written...