Skip to content

Commit

Permalink
[SUREFIRE-2137] Run JUnitPlatform ITs with latest 5.8.x/5.9.x as well
Browse files Browse the repository at this point in the history
- Add 5.8.2 and 5.9.1 to JUnitPlatformIT
- Add 5.7.2, 5.8.2 and 5.9.1 to JUnitPlatformEnginesIT
- Use most recent 5.6.x and 5.7.x patch versions in both
- Remove very old 5.0.3 and 5.1.1 from JUnitPlatformEnginesIT
- Simplify parameterization of SUREFIRE-1914-bugfix-verifying IT
  and run it against JUnit versions 5.2.0, 5.8.2 and 5.9.1 only,
  since it is just a bugfix-verifying IT after all
  • Loading branch information
andpab authored and slawekjaranowski committed Jan 3, 2023
1 parent 348bfa1 commit 6420f7c
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 36 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -74,15 +74,15 @@ public class JUnitPlatformEnginesIT extends SurefireJUnit4IntegrationTestCase
@Parameters( name = "{0}" )
public static Iterable<Object[]> artifactVersions()
{
ArrayList<Object[]> args = new ArrayList<>();
args.add( new Object[] {"1.0.3", "5.0.3", "1.0.0", "1.0.0"} );
args.add( new Object[] {"1.1.1", "5.1.1", "1.0.0", "1.0.0"} );
List<Object[]> args = new ArrayList<>();
args.add( new Object[] {"1.2.0", "5.2.0", "1.1.0", "1.0.0"} );
args.add( new Object[] {"1.3.2", "5.3.2", "1.1.1", "1.0.0"} );
args.add( new Object[] {"1.4.2", "5.4.2", "1.1.1", "1.0.0"} );
args.add( new Object[] {"1.5.2", "5.5.2", "1.2.0", "1.1.0"} );
args.add( new Object[] {"1.6.2", "5.6.2", "1.2.0", "1.1.0"} );
//args.add( new Object[] { "1.6.0-SNAPSHOT", "5.6.0-SNAPSHOT", "1.2.0", "1.1.0" } );
args.add( new Object[] {"1.6.3", "5.6.3", "1.2.0", "1.1.0"} );
args.add( new Object[] {"1.7.2", "5.7.2", "1.2.0", "1.1.0" } );
args.add( new Object[] {"1.8.2", "5.8.2", "1.2.0", "1.1.2" } );
args.add( new Object[] {"1.9.1", "5.9.1", "1.2.0", "1.1.2" } );
return args;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
*/

import java.util.ArrayList;
import java.util.List;

import org.apache.maven.surefire.its.fixture.OutputValidator;
import org.apache.maven.surefire.its.fixture.SurefireJUnit4IntegrationTestCase;
Expand Down Expand Up @@ -50,13 +51,15 @@ public class JUnitPlatformIT
@Parameters( name = "{0}" )
public static Iterable<Object[]> artifactVersions()
{
ArrayList<Object[]> args = new ArrayList<>();
List<Object[]> args = new ArrayList<>();
args.add( new Object[] { "5.2.0", "0.8.0" } );
args.add( new Object[] { "5.3.2", "0.9.0" } );
args.add( new Object[] { "5.4.2", "1.0.0" } );
args.add( new Object[] { "5.5.2", "0.8.15" } );
args.add( new Object[] { "5.6.2", "1.2.7" } );
args.add( new Object[] { "5.7.1", "1.5.0" } );
args.add( new Object[] { "5.6.2", "1.3.5" } );
args.add( new Object[] { "5.7.2", "1.5.5" } );
args.add( new Object[] { "5.8.2", "1.6.5" } );
args.add( new Object[] { "5.9.1", "1.7.1" } );
return args;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@
* under the License.
*/

import java.util.ArrayList;
import java.util.List;
import java.util.Arrays;

import org.apache.maven.surefire.its.fixture.OutputValidator;
import org.apache.maven.surefire.its.fixture.SurefireJUnit4IntegrationTestCase;
Expand All @@ -41,40 +40,19 @@ public class Surefire1914XmlReportingParameterizedTestIT extends SurefireJUnit4I
{
@Parameter
@SuppressWarnings( "checkstyle:visibilitymodifier" )
public String platform;

@Parameter( 1 )
@SuppressWarnings( "checkstyle:visibilitymodifier" )
public String jupiter;

@Parameter( 2 )
@SuppressWarnings( "checkstyle:visibilitymodifier" )
public String opentest;

@Parameter( 3 )
@SuppressWarnings( "checkstyle:visibilitymodifier" )
public String apiguardian;
public String jupiterVersion;

@Parameters( name = "{0}" )
public static Iterable<Object[]> artifactVersions()
public static Iterable<?> junitJupiterVersions()
{
List<Object[]> args = new ArrayList<>();
args.add( new Object[] {"1.0.3", "5.0.3", "1.0.0", "1.0.0"} );
args.add( new Object[] {"1.1.1", "5.1.1", "1.0.0", "1.0.0"} );
args.add( new Object[] {"1.2.0", "5.2.0", "1.1.0", "1.0.0"} );
args.add( new Object[] {"1.3.2", "5.3.2", "1.1.1", "1.0.0"} );
args.add( new Object[] {"1.4.2", "5.4.2", "1.1.1", "1.0.0"} );
args.add( new Object[] {"1.5.2", "5.5.2", "1.2.0", "1.1.0"} );
args.add( new Object[] {"1.6.2", "5.6.2", "1.2.0", "1.1.0"} );
args.add( new Object[] {"1.7.1", "5.7.1", "1.2.0", "1.1.0" } );
return args;
return Arrays.asList( "5.2.0", "5.8.2", "5.9.1" );
}

@Test
public void testXmlReport()
{
OutputValidator validator = unpack( "surefire-1914-xml-reporting-parameterizedtest", "-" + jupiter )
.sysProp( "junit5.version", jupiter )
OutputValidator validator = unpack( "surefire-1914-xml-reporting-parameterizedtest", "-" + jupiterVersion )
.sysProp( "junit5.version", jupiterVersion )
.executeTest()
.verifyErrorFree( 16 );

Expand Down

0 comments on commit 6420f7c

Please sign in to comment.