如何在 JsUnit 中创建测试套件
How to create test suite in JsUnit
如何像使用 JUnit 一样在 JsUnit 中创建测试套件?我有很多测试想 运行 一起进行。例如,我在 test1.html 和 test2.html 中有两个测试,我想将它们分组到 运行.
在您的页面中写 suite
function
returns JsUnitTestSuite
。
function suite(){
var suite = new JsUnitTestSuite();
suite.addTestPage("/path/test1.html");//use the addTestPage() method to add a test page
suite.addTestPage("/path/test2.html");
return suite;
}
如何像使用 JUnit 一样在 JsUnit 中创建测试套件?我有很多测试想 运行 一起进行。例如,我在 test1.html 和 test2.html 中有两个测试,我想将它们分组到 运行.
在您的页面中写 suite
function
returns JsUnitTestSuite
。
function suite(){
var suite = new JsUnitTestSuite();
suite.addTestPage("/path/test1.html");//use the addTestPage() method to add a test page
suite.addTestPage("/path/test2.html");
return suite;
}