Skip to content

Commit

Permalink
(chore) Improve naming of tests
Browse files Browse the repository at this point in the history
  • Loading branch information
murdos committed Sep 5, 2023
1 parent a5bf6ff commit 8335458
Showing 1 changed file with 5 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
import java.io.IOException;
import java.nio.file.Files;
import java.nio.file.Paths;
import org.junit.jupiter.api.DisplayName;
import org.junit.jupiter.api.Nested;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.ExtendWith;
Expand Down Expand Up @@ -102,8 +101,7 @@ void shouldNotGreedExistingBlocks() {
}

@Nested
@DisplayName("Scripts")
class FileSystemPackageJsonHandlerScriptsTest {
class Scripts {

@Test
void shouldAddScriptToPackageJsonWithoutScriptSection() {
Expand Down Expand Up @@ -195,8 +193,7 @@ void shouldReplaceExistingScript() {
}

@Nested
@DisplayName("Dev dependencies")
class FileSystemPackageJsonHandlerDevDependenciesTest {
class DevDependencies {

@Test
void shouldAddDevDependencyToPackageJsonWithoutDevDependencySection() {
Expand Down Expand Up @@ -292,8 +289,7 @@ private void mockDevVersion() {
}

@Nested
@DisplayName("Dependencies")
class FileSystemPackageJsonHandleDependenciesTest {
class Dependencies {

@Test
void shouldAddDependencyToPackageJsonWithoutDependencySection() {
Expand All @@ -319,7 +315,7 @@ void shouldAddDependencyToPackageJsonWithoutDependencySection() {
}

@Test
void shouldAddDevDependencyToPackageJsonWithDevDependencySection() {
void shouldAddDependencyToPackageJsonWithDependencySection() {
mockVersion();

JHipsterProjectFolder folder = projectWithPackageJson("src/test/resources/projects/node/package.json");
Expand All @@ -341,7 +337,7 @@ void shouldAddDevDependencyToPackageJsonWithDevDependencySection() {
}

@Test
void shouldReplaceExistingDevDependency() {
void shouldReplaceExistingDependency() {
mockVersion();

JHipsterProjectFolder folder = projectWithPackageJson("src/test/resources/projects/node/package.json");
Expand Down

0 comments on commit 8335458

Please sign in to comment.