You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@BeforeAll and @afterall methods are run after each test class, is there any way to call a first special method, that can be called before calling the first test method and post all test methods to call another special method.
exactly like doFirst and doLast in gradle.
i.e. these special methods are called only once first and last before first test method and post-last test method across 100s of test classes.
I tried an extension approach with @afterall but this method is called two times for two test classes.
com.tejasoft.dsa.bbraces.test.TestBB
? testBalancedBraces()
? testUnbalancedBraces()
Total 'assertEquals' Count: 264
Total 'assert*' Count: 264
com.tejasoft.dsa.bbraces.test.TestBBRandom
? testTrueThenFalseBalancedBraces()
? testFalseThenTrueBalancedBraces()
Total 'assertEquals' Count: 348
Total 'assert*' Count: 348
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
@BeforeAll and @afterall methods are run after each test class, is there any way to call a first special method, that can be called before calling the first test method and post all test methods to call another special method.
exactly like doFirst and doLast in gradle.
i.e. these special methods are called only once first and last before first test method and post-last test method across 100s of test classes.
I tried an extension approach with @afterall but this method is called two times for two test classes.
Beta Was this translation helpful? Give feedback.
All reactions