Home
last modified time | relevance | path

Searched refs:tng (Results 1 – 25 of 105) sorted by relevance

12345

/external/testng/src/test/java/test/annotationtransformer/
DAnnotationTransformerTest.java37 TestNG tng = create(AnnotationTransformerSampleTest.class); in verifyAnnotationWithoutTransformer() local
38 tng.setPreserveOrder(true); in verifyAnnotationWithoutTransformer()
41 tng.addListener(tla); in verifyAnnotationWithoutTransformer()
43 tng.run(); in verifyAnnotationWithoutTransformer()
61 TestNG tng = create(AnnotationTransformerSampleTest.class); in verifyAnnotationTransformerMethod() local
62 tng.setPreserveOrder(true); in verifyAnnotationTransformerMethod()
65 tng.setAnnotationTransformer(transformer); in verifyAnnotationTransformerMethod()
68 tng.addListener(tla); in verifyAnnotationTransformerMethod()
70 tng.run(); in verifyAnnotationTransformerMethod()
87 TestNG tng = create(AnnotationTransformerSampleTest.class); in verifyAnnotationTransformerHasOnlyOneNonNullArgument() local
[all …]
/external/testng/src/test/java/test/listeners/
DListenerTest.java30 TestNG tng = create(OrderedListenerSampleTest.class); in listenerShouldBeCalledBeforeConfiguration() local
31 tng.run(); in listenerShouldBeCalledBeforeConfiguration()
37 TestNG tng = create(FailingSampleTest.class); in failureBeforeAfterMethod() local
38 tng.run(); in failureBeforeAfterMethod()
44 TestNG tng = create(AggregateSampleTest.class); in aggregateListeners() local
46 tng.run(); in aggregateListeners()
52 TestNG tng = create(Derived1.class, Derived2.class); in shouldAttachOnlyOneInstanceOfTheSameListenerClassPerTest() local
54 tng.run(); in shouldAttachOnlyOneInstanceOfTheSameListenerClassPerTest()
60 TestNG tng = create(SuiteListenerSample.class); in suiteListenersShouldWork() local
63 tng.run(); in suiteListenersShouldWork()
[all …]
/external/testng/src/test/java/test/methodinterceptors/
DMethodInterceptorTest.java43 TestNG tng = create(); in noMethodsShouldRun() local
44 tng.setTestClasses(new Class[] { FooTest.class }); in noMethodsShouldRun()
45 testNullInterceptor(tng); in noMethodsShouldRun()
48 private void testNullInterceptor(TestNG tng) { in testNullInterceptor() argument
49 tng.setMethodInterceptor(new NullMethodInterceptor()); in testNullInterceptor()
51 tng.addListener(tla); in testNullInterceptor()
52 tng.run(); in testNullInterceptor()
60 TestNG tng = create(); in testFast() local
61 tng.setTestClasses(new Class[] { FooTest.class }); in testFast()
63 tng.setMethodInterceptor(new FastTestsFirstInterceptor()); in testFast()
[all …]
/external/testng/src/test/java/test/sanitycheck/
DCheckTestNamesTest.java39 TestNG tng = create(); in runSuite() local
41 tng.setTestSuites(Arrays.asList(testngXmlPath)); in runSuite()
42 tng.addListener(tla); in runSuite()
43 tng.run(); in runSuite()
58 TestNG tng = create(); in checkNoError() local
60 tng.setTestSuites(Arrays.asList(testngXmlPath)); in checkNoError()
61 tng.addListener(tla); in checkNoError()
62 tng.run(); in checkNoError()
72 TestNG tng = create(); in checkNoErrorWtihChildSuites() local
74 tng.setTestSuites(Arrays.asList(testngXmlPath)); in checkNoErrorWtihChildSuites()
[all …]
DCheckSuiteNamesTest.java25 TestNG tng = create(); in checkChildSuites() local
27 tng.setTestSuites(Arrays.asList(testngXmlPath)); in checkChildSuites()
28 tng.addListener(tla); in checkChildSuites()
29 tng.run(); in checkChildSuites()
39 TestNG tng = create(); in checkChildSuitesFails() local
41 tng.setTestSuites(Arrays.asList(testngXmlPath)); in checkChildSuitesFails()
42 tng.addListener(tla); in checkChildSuitesFails()
43 tng.run(); in checkChildSuitesFails()
69 TestNG tng = create(); in checkProgrammaticSuitesFails() local
70 tng.setXmlSuites(Arrays.asList(xmlSuite1, xmlSuite2)); in checkProgrammaticSuitesFails()
[all …]
/external/testng/src/test/java/test/thread/
DParallelSuiteTest.java33 TestNG tng = create(); in suitesShouldRunInParallel3() local
34 tng.setSuiteThreadPoolSize(SUITE_THREAD_POOL_SIZE); in suitesShouldRunInParallel3()
35 tng.setTestSuites(Arrays.asList(getPathToResource("suite-parallel-0.xml"))); in suitesShouldRunInParallel3()
36 tng.addListener(tla); in suitesShouldRunInParallel3()
39 tng.run(); //Shouldn't not deadlock in suitesShouldRunInParallel3()
46 TestNG tng = create(); in runTest() local
47 tng.setSuiteThreadPoolSize(suiteThreadPoolSize); in runTest()
48 tng.setTestSuites(paths); in runTest()
49 tng.addListener(tla); in runTest()
51 tng.setRandomizeSuites(randomizeSuites); in runTest()
[all …]
DDataProviderThreadPoolSizeTest.java13 TestNG tng = create(DataProviderThreadPoolSizeSampleTest.class); in shouldUseDefaultDataProviderThreadCount() local
14 tng.setGroups("parallel"); in shouldUseDefaultDataProviderThreadCount()
15 tng.run(); in shouldUseDefaultDataProviderThreadCount()
21 TestNG tng = create(DataProviderThreadPoolSizeSampleTest.class); in shouldNotUseThreadsIfNotUsingParallel() local
22 tng.setGroups("sequential"); in shouldNotUseThreadsIfNotUsingParallel()
23 tng.run(); in shouldNotUseThreadsIfNotUsingParallel()
29 TestNG tng = create(DataProviderThreadPoolSizeSampleTest.class); in shouldUseSpecifiedDataProviderThreadCount() local
30 tng.setGroups("parallel"); in shouldUseSpecifiedDataProviderThreadCount()
31 tng.setDataProviderThreadCount(3); in shouldUseSpecifiedDataProviderThreadCount()
32 tng.run(); in shouldUseSpecifiedDataProviderThreadCount()
DFactoryTest.java35 TestNG tng = new TestNG(); in runTest() local
36 tng.setVerbose(0); in runTest()
37 tng.setTestClasses(new Class[] { FactorySampleTest.class}); in runTest()
39 tng.setParallel(parallelMode); in runTest()
42 tng.addListener(tla); in runTest()
45 tng.run(); in runTest()
/external/testng/src/test/java/test/name/
DNameTest.java20 TestNG tng = create(SimpleITestSample.class); in itestTest() local
22 tng.addListener(adapter); in itestTest()
24 tng.run(); in itestTest()
37 TestNG tng = createTests("suite", SimpleITestSample.class); in itestTestWithXml() local
39 tng.addListener(adapter); in itestTestWithXml()
41 tng.run(); in itestTestWithXml()
54 TestNG tng = create(NameSample.class); in testNameTest() local
56 tng.addListener(adapter); in testNameTest()
58 tng.run(); in testNameTest()
71 TestNG tng = createTests("suite", NameSample.class); in testNameTestWithXml() local
[all …]
/external/testng/src/test/java/test/serviceloader/
DServiceLoaderTest.java18 TestNG tng = create(ServiceLoaderSampleTest.class); in serviceLoaderShouldWork() local
21 tng.setServiceLoaderClassLoader(ucl); in serviceLoaderShouldWork()
22 tng.run(); in serviceLoaderShouldWork()
24 ListenerAssert.assertListenerType(tng.getServiceLoaderListeners(), TmpSuiteListener.class); in serviceLoaderShouldWork()
35 TestNG tng = create(ServiceLoaderSampleTest.class); in serviceLoaderWithNoClassLoader() local
36 tng.run(); in serviceLoaderWithNoClassLoader()
38 ListenerAssert.assertListenerType(tng.getServiceLoaderListeners(), TmpSuiteListener.class); in serviceLoaderWithNoClassLoader()
43 TestNG tng = create(ServiceLoaderSampleTest.class); in serviceLoaderShouldWorkWithConfigurationListener() local
44 tng.run(); in serviceLoaderShouldWorkWithConfigurationListener()
46 Assert.assertEquals(1, tng.getServiceLoaderListeners().size()); in serviceLoaderShouldWorkWithConfigurationListener()
[all …]
/external/testng/src/test/java/test/methodinterceptors/multipleinterceptors/
DMultipleInterceptorsTest.java16 TestNG tng = create(FooTest.class); in testMultipleInterceptors() local
17 tng.setMethodInterceptor(new FirstInterceptor()); in testMultipleInterceptors()
18 tng.setMethodInterceptor(new SecondInterceptor()); in testMultipleInterceptors()
19 tng.setMethodInterceptor(new ThirdInterceptor()); in testMultipleInterceptors()
21 tng.addListener(tla); in testMultipleInterceptors()
22 tng.run(); in testMultipleInterceptors()
29 TestNG tng = create(); in testMultipleInterceptorsWithPreserveOrder() local
30 tng.setTestSuites(Collections.singletonList( in testMultipleInterceptorsWithPreserveOrder()
33 tng.addListener(tla); in testMultipleInterceptorsWithPreserveOrder()
34 tng.run(); in testMultipleInterceptorsWithPreserveOrder()
/external/testng/src/test/java/test/retryAnalyzer/
DExitCodeTest.java13 TestNG tng = create(ImmediateSuccess.class); in exitsWithZeroOnSuccess() local
14 tng.run(); in exitsWithZeroOnSuccess()
15 assertEquals(tng.getStatus(), 0); in exitsWithZeroOnSuccess()
20 TestNG tng = create(PersistentFailure.class); in exitsWithNonzeroOnFailure() local
21 tng.run(); in exitsWithNonzeroOnFailure()
22 assertTrue(tng.getStatus() != 0); in exitsWithNonzeroOnFailure()
27 TestNG tng = create(EventualSuccess.class); in exitsWithZeroAfterSuccessfulRetry() local
28 tng.run(); in exitsWithZeroAfterSuccessfulRetry()
29 assertEquals(tng.getStatus(), 0); in exitsWithZeroAfterSuccessfulRetry()
/external/testng/src/test/java/test/objectfactory/
DCustomFactoryTest.java19 TestNG tng = TestHelper.createTestNG(suite); in setFactoryOnTestNG() local
20 tng.setObjectFactory(LoggingObjectFactory.class); in setFactoryOnTestNG()
21 tng.run(); in setFactoryOnTestNG()
35 TestNG tng = TestHelper.createTestNG(suite); in setFactoryOnSuite() local
36 tng.run(); in setFactoryOnSuite()
46 TestNG tng = TestHelper.createTestNG(suite); in setFactoryByAnnotation() local
47 tng.run(); in setFactoryByAnnotation()
57 TestNG tng = TestHelper.createTestNG(suite); in factoryReceivesContext() local
58 tng.run(); in factoryReceivesContext()
66 TestNG tng = TestHelper.createTestNG(suite); in setInvalidMethodFactoryByAnnotation() local
[all …]
/external/testng/src/test/java/test/parameters/
DParamInheritanceTest.java24 TestNG tng = create(); in noNPEInCountingResults() local
25 tng.setTestSuites(Arrays.asList(getPathToResource("param-inheritance/parent-suite.xml"))); in noNPEInCountingResults()
26 tng.setVerbose(2); in noNPEInCountingResults()
27 tng.addListener(tla); in noNPEInCountingResults()
38 tng.run(); in noNPEInCountingResults()
56 TestNG tng = create(); in parameterInheritanceAndOverriding() local
57 tng.setUseDefaultListeners(false); in parameterInheritanceAndOverriding()
58 tng.setTestSuites(Arrays.asList(getPathToResource("parametertest/parent-suite.xml"))); in parameterInheritanceAndOverriding()
59 tng.addListener(tla); in parameterInheritanceAndOverriding()
60 tng.run(); in parameterInheritanceAndOverriding()
/external/testng/src/test/java/test/preserveorder/
DPreserveOrderTest.java30 TestNG tng = create(); in preserveClassOrder() local
40 tng.setXmlSuites(Arrays.asList(s)); in preserveClassOrder()
41 tng.run(); in preserveClassOrder()
71 TestNG tng = create(); in preserveMethodOrder() local
79 tng.setXmlSuites(Arrays.asList(s)); in preserveMethodOrder()
80 tng.run(); in preserveMethodOrder()
94 TestNG tng = create(); in orderShouldBePreservedWithDependencies() local
100 tng.setXmlSuites(Arrays.asList(s)); in orderShouldBePreservedWithDependencies()
102 tng.addListener(tla); in orderShouldBePreservedWithDependencies()
103 tng.run(); in orderShouldBePreservedWithDependencies()
[all …]
/external/testng/src/test/java/test/invokedmethodlistener/
DInvokedMethodListenerTest.java18 TestNG tng = create(); in run() local
19 tng.setTestClasses(classes); in run()
21 tng.addInvokedMethodListener(l); in run()
22 tng.run(); in run()
59 TestNG tng = create(Sample.class); in sameMethodInvokedMultipleTimesShouldHaveDifferentTimeStamps() local
61 tng.addListener(listener); in sameMethodInvokedMultipleTimesShouldHaveDifferentTimeStamps()
62 tng.run(); in sameMethodInvokedMultipleTimesShouldHaveDifferentTimeStamps()
79 TestNG tng = create(Sample2.class); in testMethodsWithExpectedExceptionsShouldShowUpAsPass() local
81 tng.addListener(l); in testMethodsWithExpectedExceptionsShouldShowUpAsPass()
82 tng.run(); in testMethodsWithExpectedExceptionsShouldShowUpAsPass()
[all …]
/external/testng/src/test/java/test/enable/
DEnableTest.java14 TestNG tng = create(A.class, B.class, C.class); in disabled_methods_should_not_be_run() local
16 tng.addListener(listener); in disabled_methods_should_not_be_run()
17 tng.setPreserveOrder(true); in disabled_methods_should_not_be_run()
18 tng.run(); in disabled_methods_should_not_be_run()
33 TestNG tng = create(Issue420FirstSample.class, Issue420SecondSample.class); in issue420() local
35 tng.addListener(listener); in issue420()
36 tng.run(); in issue420()
/external/testng/src/test/java/test/testng173/
DTestNG173Test.java20 TestNG tng = create(); in orderShouldBePreservedInMethodsWithSameNameAndInDifferentClasses() local
29 tng.setXmlSuites(Arrays.asList(s)); in orderShouldBePreservedInMethodsWithSameNameAndInDifferentClasses()
32 tng.addListener(tla); in orderShouldBePreservedInMethodsWithSameNameAndInDifferentClasses()
33 tng.run(); in orderShouldBePreservedInMethodsWithSameNameAndInDifferentClasses()
44 TestNG tng = create(); in orderShouldBePreservedInMethodsWithSameNameAndInDifferentClassesAndDifferentPackage() local
53 tng.setXmlSuites(Arrays.asList(s)); in orderShouldBePreservedInMethodsWithSameNameAndInDifferentClassesAndDifferentPackage()
56 tng.addListener(tla); in orderShouldBePreservedInMethodsWithSameNameAndInDifferentClassesAndDifferentPackage()
57 tng.run(); in orderShouldBePreservedInMethodsWithSameNameAndInDifferentClassesAndDifferentPackage()
/external/testng/src/test/java/test/verify/
DVerifyTest.java13 TestNG tng = create(cls); in runTest() local
15 tng.addListener(tla); in runTest()
16 tng.run(); in runTest()
33 TestNG tng = create(Verify2SampleTest.class); in verifyTestListener() local
35 tng.run(); in verifyTestListener()
41 TestNG tng = create(Verify3SampleTest.class); in verifyBaseClassTestListener() local
43 tng.run(); in verifyBaseClassTestListener()
/external/testng/src/test/java/test/factory/
DFactoryIntegrationTest.java17 TestNG tng = create(GitHub876Sample.class); in testExceptionWithNonStaticFactoryMethod() local
19 tng.run(); in testExceptionWithNonStaticFactoryMethod()
28 TestNG tng = create(NonPublicFactoryMethodSample.class); in testNonPublicFactoryMethodShouldWork() local
30 tng.addListener(tla); in testNonPublicFactoryMethodShouldWork()
32 tng.run(); in testNonPublicFactoryMethodShouldWork()
39 TestNG tng = create(BadFactoryMethodReturnTypeSample.class); in testExceptionWithBadFactoryMethodReturnType() local
41 tng.run(); in testExceptionWithBadFactoryMethodReturnType()
/external/testng/src/test/java/test/inheritance/testng471/
DTestNG471.java15 TestNG tng = create(Class1.class, Class2.class, Class3.class); in test_classes_should_not_be_skipped_when_a_after_method_fails() local
16 tng.setPreserveOrder(true); in test_classes_should_not_be_skipped_when_a_after_method_fails()
17 tng.setVerbose(10); in test_classes_should_not_be_skipped_when_a_after_method_fails()
19 tng.setPreserveOrder(true); in test_classes_should_not_be_skipped_when_a_after_method_fails()
20 tng.addListener(listener); in test_classes_should_not_be_skipped_when_a_after_method_fails()
22 tng.run(); in test_classes_should_not_be_skipped_when_a_after_method_fails()
/external/testng/src/test/java/test/testng387/
DTestNG387.java16 final TestNG tng = create(FailedDPTest.class); in testInvocationCounterIsCorrectForMethodWithDataProvider() local
17 tng.setThreadCount(1); in testInvocationCounterIsCorrectForMethodWithDataProvider()
18 tng.setParallel(XmlSuite.ParallelMode.FALSE); in testInvocationCounterIsCorrectForMethodWithDataProvider()
19 tng.setPreserveOrder(true); in testInvocationCounterIsCorrectForMethodWithDataProvider()
21 tng.addListener(tla); in testInvocationCounterIsCorrectForMethodWithDataProvider()
22 tng.run(); in testInvocationCounterIsCorrectForMethodWithDataProvider()
/external/testng/src/test/java/test/methodselectors/
DMethodSelectorInSuiteTest.java32 TestNG tng = create(); in programmaticXmlSuite() local
43 tng.setXmlSuites(Arrays.asList(suite)); in programmaticXmlSuite()
44 tng.addListener(m_tla); in programmaticXmlSuite()
45 tng.run(); in programmaticXmlSuite()
52 TestNG tng = create(); in xmlXmlSuite() local
53 tng.setTestSuites(Arrays.asList(getPathToResource("methodselector-in-xml.xml"))); in xmlXmlSuite()
54 tng.addListener(m_tla); in xmlXmlSuite()
55 tng.run(); in xmlXmlSuite()
/external/testng/src/test/java/test/dataprovider/
DTestContextTest.java27 TestNG tng = new TestNG(); in verify() local
28 tng.setVerbose(0); in verify()
29 tng.setTestClasses(new Class[] { TestContextSampleTest.class }); in verify()
31 tng.setGroups(groupName); in verify()
34 tng.addListener(al); in verify()
35 tng.run(); in verify()
/external/testng/src/test/java/test/multiplelisteners/
DTestMaker.java20 final TestNG tng = new TestNG(); in run() local
21 tng.setUseDefaultListeners(false); in run()
22 tng.setListenerClasses(Arrays.<Class> asList(TestListenerAdapter.class, SimpleReporter.class)); in run()
24 tng.setXmlSuites(suites); in run()
25 tng.setVerbose(0); in run()
26 tng.run(); in run()

12345