as we are upgrading to junit5 from junit4 for unit testing purpose, i couldn't able to find solution to creating a test suite in junit5 like in junit4 : below is the our junit4 suite class :
@RunWith(Suite.class)
@SuiteClasses({
ClassA.class,
ClassB.class,
ClassC.class
} )
public class TestSuite {
}
The Code i tried after searching around is below :
@RunWith(JUnitPlatform.class)
@SelectClasses( {
OrderAnnotationAlphanumericExperiment.class,
orderAnnotationExperiment.class,
ParameterizedAnnotation.class
} )
public class TestSuite {
}
on searching for the solution, most of them were providing a solution of using the same test suite to run it using vintage api, but what am looking for is to create test suite in junit 5.
Few suggesting @ExtendsWith(SpringExtension.class), but there is also less documentation for it, couldn't able to find a solution to create a suite in junit 5
few blogs/question/sites i referred :
Create TestSuite in JUnit5 (Eclipse) Are test suites considered deprecated in JUnit5? https://howtodoinjava.com/junit5/junit5-test-suites-examples/
some one help me out to solve this problem.