Skip to content

Commit

Permalink
[MSHARED-1152] Remove public modifier for JUnit5 tests
Browse files Browse the repository at this point in the history
  • Loading branch information
slawekjaranowski committed May 5, 2024
1 parent d956445 commit fa7e249
Show file tree
Hide file tree
Showing 5 changed files with 110 additions and 110 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ under the License.
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter</artifactId>
<artifactId>junit-jupiter-api</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,19 +34,19 @@
import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.junit.jupiter.api.Assertions.assertTrue;

public class DefaultInvokerTest {
class DefaultInvokerTest {

private Invoker invoker = newInvoker();
private InvocationRequest request = new DefaultInvocationRequest();

@BeforeEach
public void setUp() throws Exception {
void setUp() throws Exception {
request.setDebug(true);
request.setProperties(getProperties());
}

@Test
public void testBuildShouldSucceed() throws MavenInvocationException, URISyntaxException {
void testBuildShouldSucceed() throws MavenInvocationException, URISyntaxException {
File basedir = getBasedirForBuild();
request.setBaseDirectory(basedir);
request.setGoals(Arrays.asList("clean", "package"));
Expand All @@ -57,7 +57,7 @@ public void testBuildShouldSucceed() throws MavenInvocationException, URISyntaxE
}

@Test
public void testBuildShouldFail() throws MavenInvocationException, URISyntaxException {
void testBuildShouldFail() throws MavenInvocationException, URISyntaxException {
File basedir = getBasedirForBuild();
request.setBaseDirectory(basedir);
request.setGoals(Arrays.asList("clean", "package"));
Expand All @@ -68,7 +68,7 @@ public void testBuildShouldFail() throws MavenInvocationException, URISyntaxExce
}

@Test
public void testBuildShouldTimeout() throws MavenInvocationException, URISyntaxException {
void testBuildShouldTimeout() throws MavenInvocationException, URISyntaxException {
File basedir = getBasedirForBuild();
request.setBaseDirectory(basedir);
request.setGoals(Arrays.asList("clean", "package"));
Expand All @@ -89,7 +89,7 @@ public void testBuildShouldTimeout() throws MavenInvocationException, URISyntaxE
}

@Test
public void testSpacePom() throws Exception {
void testSpacePom() throws Exception {
File basedir = getBasedirForBuild();
request.setBaseDirectory(basedir);
request.setPomFileName("pom with spaces.xml");
Expand All @@ -101,7 +101,7 @@ public void testSpacePom() throws Exception {
}

@Test
public void testSpaceAndSpecialCharPom() throws Exception {
void testSpaceAndSpecialCharPom() throws Exception {
File basedir = getBasedirForBuild();
request.setBaseDirectory(basedir);
request.setPomFileName("pom with spaces & special char.xml");
Expand All @@ -113,7 +113,7 @@ public void testSpaceAndSpecialCharPom() throws Exception {
}

@Test
public void testSpaceSettings() throws Exception {
void testSpaceSettings() throws Exception {
File basedir = getBasedirForBuild();
request.setBaseDirectory(basedir);
request.setUserSettingsFile(new File(basedir, "settings with spaces.xml"));
Expand All @@ -125,7 +125,7 @@ public void testSpaceSettings() throws Exception {
}

@Test
public void testSpaceLocalRepo() throws Exception {
void testSpaceLocalRepo() throws Exception {
File basedir = getBasedirForBuild();
request.setBaseDirectory(basedir);
request.setLocalRepositoryDirectory(new File(basedir, "repo with spaces"));
Expand All @@ -137,7 +137,7 @@ public void testSpaceLocalRepo() throws Exception {
}

@Test
public void testSpaceProperties() throws Exception {
void testSpaceProperties() throws Exception {
File basedir = getBasedirForBuild();
request.setBaseDirectory(basedir);
Properties props = getProperties();
Expand All @@ -152,7 +152,7 @@ public void testSpaceProperties() throws Exception {
}

@Test
public void testPomOutsideProject() throws Exception {
void testPomOutsideProject() throws Exception {
File basedir = getBasedirForBuild();
request.setBaseDirectory(basedir);
File pom = new File(basedir, "temp/pom.xml");
Expand All @@ -165,7 +165,7 @@ public void testPomOutsideProject() throws Exception {
}

@Test
public void testMavenWrapperInProject() throws Exception {
void testMavenWrapperInProject() throws Exception {
File basedir = getBasedirForBuild();
request.setBaseDirectory(basedir);
request.setGoals(Collections.singletonList("test-wrapper-goal"));
Expand Down
Loading

0 comments on commit fa7e249

Please sign in to comment.