suite

Is there a way to specify parameters for included methods in TestNG suite.xml?

倾然丶 夕夏残阳落幕 提交于 2019-12-20 04:14:26
问题 I'm writing a suite.xml for an own testframework based on TestNG. My xml file looks like: <!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd" > <suite name="Suite" parallel="methods"> <test name="NewTest"> <parameter name="BROWSER" value="Chrome"></parameter> <classes> <class name="hm.NewTest"> <methods> <include name="test"></include> <include name="test2"></include> <include name="test3"></include> <include name="test4"></include> </methods> </class> </classes> </test> </suite> The

test suite python - webdriver

笑着哭i 提交于 2019-12-19 09:45:32
问题 I'm new with python, and I'm trying to create my own test suite. The main pourpose is to execute the same test on different browser, that's why I used the variable browser, that is used within the test to call the webdriver. I have this: def test_01(self,browser): def test_02(self,browser): my Suite: def suite(): test_suite = unittest.TestSuite() suite.addTest(unittest.makeSuite(Test01)) return test_suite main: if __name__ == "__main__": suite1 = unittest.TestSuite() self = Test01() suite1

Running JUnit Test in parallel on Suite Level?

久未见 提交于 2019-12-18 13:14:45
问题 I have a bunch of tests that are organized in JUnit test suites. These tests are greatly utilizing selenium to test a web application. So, naturaly for selenium, the runtime of these tests is quite long. Since the test classes in the suites can not run parallel due some overlaps in the test database, i would like to run the suites parallel. The JUnit ParallelComputer can only execute tests on class or method level in parallel, are there any standard ways for JUnit to do that with suites? If i

android - accessing test application assets

有些话、适合烂在心里 提交于 2019-12-06 22:45:15
问题 I've an XML file in the assets directory of my test application. I want to access this file from my suite method of the test class. ie., public static TestSuite suite(){ InputStream stream = // Some code which returns the asset } Any idea how I can do this? I tried with Resources.Resources.getSystem().getAssets() but no luck :-(. help please. Thanx in adv, Joseph 回答1: I encountered the same problem with my test app. Unfortunately, it looks like getContext() in a test case class actually

In mono, how to control the SSL/TLS cipher suite?

这一生的挚爱 提交于 2019-12-06 11:47:45
问题 I would like to configure the server to refuse negotation of DES, RC4, MD5, etc. The mono 3.4 release notes say "Network Stack Now allows developers to control which cipher suites to use with TLS/SSL." ... But how? 回答1: (Thanks to Sebastien Pouliot for this answer) You can set a callback for either ClientCipherSuitesCallback or ServerCipherSuitesCallback SSL/TLS. That will allow you to control which ciphers can be used and the selection order (in general most server select the first cipher

Spring 3+ How to create a TestSuite when JUnit is not recognizing it

蓝咒 提交于 2019-12-04 23:30:42
问题 I'm using Spring 3.0.4 and JUnit 4.5. My test classes currently uses Spring's annotation test support with the following syntax: @RunWith(SpringJUnit4ClassRunner.class) @ContextConfiguration (locations = { "classpath:configTest.xml" }) @TransactionConfiguration (transactionManager = "txManager", defaultRollback = true) @Transactional public class MyAppTest extends TestCase { @Autowired @Qualifier("myAppDAO") private IAppDao appDAO; ... } I don't really need the line extends TestCase to run

In mono, how to control the SSL/TLS cipher suite?

偶尔善良 提交于 2019-12-04 17:32:41
I would like to configure the server to refuse negotation of DES, RC4, MD5, etc. The mono 3.4 release notes say "Network Stack Now allows developers to control which cipher suites to use with TLS/SSL." ... But how? Edward Ned Harvey (Thanks to Sebastien Pouliot for this answer) You can set a callback for either ClientCipherSuitesCallback or ServerCipherSuitesCallback SSL/TLS. That will allow you to control which ciphers can be used and the selection order (in general most server select the first cipher suites they support). Sample code is part of the documentation. And also, since it will

Spring 3+ How to create a TestSuite when JUnit is not recognizing it

本秂侑毒 提交于 2019-12-03 14:28:17
I'm using Spring 3.0.4 and JUnit 4.5. My test classes currently uses Spring's annotation test support with the following syntax: @RunWith(SpringJUnit4ClassRunner.class) @ContextConfiguration (locations = { "classpath:configTest.xml" }) @TransactionConfiguration (transactionManager = "txManager", defaultRollback = true) @Transactional public class MyAppTest extends TestCase { @Autowired @Qualifier("myAppDAO") private IAppDao appDAO; ... } I don't really need the line extends TestCase to run this test. It's not needed when running this test class by itself. I had to add extends TestCase so that

Running JUnit Test in parallel on Suite Level?

天大地大妈咪最大 提交于 2019-12-03 06:08:58
I have a bunch of tests that are organized in JUnit test suites. These tests are greatly utilizing selenium to test a web application. So, naturaly for selenium, the runtime of these tests is quite long. Since the test classes in the suites can not run parallel due some overlaps in the test database, i would like to run the suites parallel. The JUnit ParallelComputer can only execute tests on class or method level in parallel, are there any standard ways for JUnit to do that with suites? If i just pass suite classes to the junit runner and configure the computer to parallelize on class level,

Is there a way to specify parameters for included methods in TestNG suite.xml?

ε祈祈猫儿з 提交于 2019-12-02 03:05:22
I'm writing a suite.xml for an own testframework based on TestNG. My xml file looks like: <!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd" > <suite name="Suite" parallel="methods"> <test name="NewTest"> <parameter name="BROWSER" value="Chrome"></parameter> <classes> <class name="hm.NewTest"> <methods> <include name="test"></include> <include name="test2"></include> <include name="test3"></include> <include name="test4"></include> </methods> </class> </classes> </test> </suite> The parameter "BROWSER" is now specified for the complete test. But i need an own parameter for each of the