File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed
testng-core/src/test/java/test/dataprovider Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change 61
61
import test .dataprovider .issue3045 .DataProviderWithoutListenerTestClassSample ;
62
62
import test .dataprovider .issue3081 .NoOpMethodInterceptor ;
63
63
import test .dataprovider .issue3081 .TestClassWithPrioritiesSample ;
64
+ import test .dataprovider .issue3236 .CacheTest ;
64
65
65
66
public class DataProviderTest extends SimpleBaseTest {
66
67
@@ -716,6 +717,16 @@ public void testIfDataProviderListenerInvokedOnlyOncePerDataProviderWhenListener
716
717
runTest (DataProviderWithoutListenerTestClassSample .class , true );
717
718
}
718
719
720
+ @ Test (description = "GITHUB-2819" )
721
+ public void testDataProviderReturnsFreshDataWhenTestRetried () {
722
+ TestNG testng = create (CacheTest .class );
723
+ TestListenerAdapter tla = new TestListenerAdapter ();
724
+ testng .addListener (tla );
725
+ testng .run ();
726
+ assertThat (tla .getFailedTests ()).size ().isEqualTo (0 );
727
+ assertThat (tla .getSkippedTests ()).size ().isEqualTo (1 );
728
+ }
729
+
719
730
private static void runTest (Class <?> clazz , boolean wireInListener ) {
720
731
DataProviderListener .logs .clear ();
721
732
TestNG testng = new TestNG ();
You can’t perform that action at this time.
0 commit comments