Skip to content

Commit 3ea0c00

Browse files
committed
Make spring-java-junit-jupiter standalone
1 parent 2e6b10e commit 3ea0c00

File tree

29 files changed

+74
-92
lines changed

29 files changed

+74
-92
lines changed

.github/workflows/test-java.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ jobs:
2222
- calculator-java-junit-jupiter
2323
- calculator-java-testng
2424
- calculator-kotlin-junit-jupiter
25+
- spring-java-junit-jupiter
2526

2627
name: 'Test ${{ matrix.example }}'
2728
runs-on: ubuntu-latest

calculator-java-cli/src/test/resources/cucumber.properties

Lines changed: 0 additions & 1 deletion
This file was deleted.

calculator-java-junit-4/src/test/resources/cucumber.properties

Lines changed: 0 additions & 1 deletion
This file was deleted.

calculator-java-junit-jupiter/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<modelVersion>4.0.0</modelVersion>
44

55
<groupId>io.cucumber.examples</groupId>
6-
<artifactId>calculator-java-junit5</artifactId>
6+
<artifactId>calculator-java-junit-jupiter</artifactId>
77
<version>0.0.1</version>
88
<packaging>jar</packaging>
99

calculator-java-junit-jupiter/src/test/resources/junit-platform.properties

Lines changed: 0 additions & 2 deletions
This file was deleted.

calculator-java-testng/src/test/resources/cucumber.properties

Lines changed: 0 additions & 1 deletion
This file was deleted.

calculator-java8-cli/src/test/resources/cucumber.properties

Lines changed: 0 additions & 1 deletion
This file was deleted.

calculator-kotlin-junit-jupiter/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
<version>0.0.1</version>
1010
<packaging>jar</packaging>
1111

12-
<name>Calculator - Kotlin - Annotations - Junit Jupiter</name>
12+
<name>Calculator - Kotlin - Annotations - Junit 5</name>
1313

1414
<properties>
1515
<kotlin.code.style>official</kotlin.code.style>
@@ -135,7 +135,7 @@
135135
</goals>
136136
<configuration>
137137
<target unless="maven.test.skip">
138-
<echo message="Running JUnit Platform CLI" level="info" />
138+
<echo message="Running JUnit Platform CLI"/>
139139
<java classname="org.junit.platform.console.ConsoleLauncher" fork="true"
140140
failonerror="true" newenvironment="true" maxmemory="512m"
141141
classpathref="maven.test.classpath">

examples/spring-java-junit5/src/test/resources/junit-platform.properties

Lines changed: 0 additions & 2 deletions
This file was deleted.

examples/spring-java-junit5/pom.xml renamed to spring-java-junit-jupiter/pom.xml

Lines changed: 21 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -1,49 +1,41 @@
11
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
22
<modelVersion>4.0.0</modelVersion>
3-
3+
44
<parent>
5-
<groupId>io.cucumber</groupId>
6-
<artifactId>examples</artifactId>
7-
<version>7.33.0-SNAPSHOT</version>
5+
<groupId>org.springframework.boot</groupId>
6+
<artifactId>spring-boot-starter-parent</artifactId>
7+
<version>4.0.0</version>
8+
<relativePath/> <!-- lookup parent from repository -->
89
</parent>
10+
11+
<groupId>io.cucumber.examples</groupId>
12+
<artifactId>spring-java-junit-jupiter</artifactId>
13+
<version>0.0.1</version>
14+
<packaging>jar</packaging>
915

10-
<artifactId>spring-java-junit5</artifactId>
11-
<name>Examples: Spring Transactions - Java - Annotations - Junit Jupiter</name>
16+
<name>Spring Transactions - Java - Annotations - Junit Jupiter</name>
1217

1318
<properties>
14-
<project.Automatic-Module-Name>io.cucumber.examples.spring.application</project.Automatic-Module-Name>
15-
<spring-boot.version>3.5.0</spring-boot.version>
16-
<junit.version>5.14.0</junit.version>
19+
<java.version>17</java.version>
1720
</properties>
1821

1922
<dependencyManagement>
2023
<dependencies>
21-
<dependency>
22-
<groupId>org.junit</groupId>
23-
<artifactId>junit-bom</artifactId>
24-
<version>${junit.version}</version>
25-
<type>pom</type>
26-
<scope>import</scope>
27-
</dependency>
28-
<dependency>
29-
<groupId>org.springframework.boot</groupId>
30-
<artifactId>spring-boot-dependencies</artifactId>
31-
<version>${spring-boot.version}</version>
32-
<type>pom</type>
33-
<scope>import</scope>
34-
</dependency>
3524
<dependency>
3625
<groupId>io.cucumber</groupId>
3726
<artifactId>cucumber-bom</artifactId>
38-
<version>${project.version}</version>
27+
<version>7.32.0</version>
3928
<type>pom</type>
4029
<scope>import</scope>
4130
</dependency>
42-
4331
</dependencies>
4432
</dependencyManagement>
4533

4634
<dependencies>
35+
<dependency>
36+
<groupId>org.springframework.boot</groupId>
37+
<artifactId>spring-boot-starter</artifactId>
38+
</dependency>
4739
<dependency>
4840
<groupId>org.springframework.boot</groupId>
4941
<artifactId>spring-boot-starter-web</artifactId>
@@ -60,18 +52,20 @@
6052
<groupId>com.h2database</groupId>
6153
<artifactId>h2</artifactId>
6254
</dependency>
63-
6455
<dependency>
6556
<groupId>org.springframework.boot</groupId>
6657
<artifactId>spring-boot-devtools</artifactId>
6758
<optional>true</optional>
6859
</dependency>
69-
7060
<dependency>
7161
<groupId>org.springframework.boot</groupId>
7262
<artifactId>spring-boot-starter-test</artifactId>
7363
<scope>test</scope>
7464
</dependency>
65+
<dependency>
66+
<groupId>org.springframework.boot</groupId>
67+
<artifactId>spring-boot-starter-webmvc-test</artifactId>
68+
</dependency>
7569
<dependency>
7670
<groupId>io.cucumber</groupId>
7771
<artifactId>cucumber-spring</artifactId>
@@ -96,13 +90,6 @@
9690

9791
<build>
9892
<plugins>
99-
<plugin>
100-
<groupId>org.apache.maven.plugins</groupId>
101-
<artifactId>maven-compiler-plugin</artifactId>
102-
<configuration>
103-
<parameters>true</parameters>
104-
</configuration>
105-
</plugin>
10693
<plugin>
10794
<groupId>org.apache.maven.plugins</groupId>
10895
<artifactId>maven-surefire-plugin</artifactId>
@@ -116,12 +103,6 @@
116103
</properties>
117104
</configuration>
118105
</plugin>
119-
120-
<plugin>
121-
<groupId>org.springframework.boot</groupId>
122-
<artifactId>spring-boot-maven-plugin</artifactId>
123-
<version>3.2.0</version>
124-
</plugin>
125106
</plugins>
126107
</build>
127108

0 commit comments

Comments
 (0)