Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename module with empty #5271

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -89,10 +89,10 @@ public enum JHLiteModuleSlug implements JHipsterModuleSlugFactory {
SPRING_BOOT_OAUTH_2_AUTH_0("spring-boot-oauth2-auth0"),
SPRING_BOOT_OAUTH_2_OKTA("spring-boot-oauth2-okta"),
SPRING_BOOT_PULSAR("spring-boot-pulsar"),
SPRING_BOOT_MVC("spring-boot-mvc"),
SPRING_BOOT_MVC_EMPTY("spring-boot-mvc-empty"),
SPRING_BOOT_TOMCAT("spring-boot-tomcat"),
SPRING_BOOT_UNDERTOW("spring-boot-undertow"),
SPRING_BOOT_WEBFLUX("spring-boot-webflux"),
SPRING_BOOT_WEBFLUX_EMPTY("spring-boot-webflux-empty"),
SPRING_BOOT_WEBFLUX_NETTY("spring-boot-webflux-netty"),
SPRING_CLOUD("spring-cloud"),
SPRINGDOC_JWT("springdoc-jwt"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ class SpringBootMvcModulesConfiguration {
JHipsterModuleResource springBootMvcModule(SpringBootMvcApplicationService springBootMvc) {
return JHipsterModuleResource
.builder()
.slug(SPRING_BOOT_MVC)
.slug(SPRING_BOOT_MVC_EMPTY)
.propertiesDefinition(properties())
.apiDoc(SPRING_BOOT_MVC_API_GROUP, "Add Spring Boot MVC")
.apiDoc(SPRING_BOOT_MVC_API_GROUP, "Empty module: do not use alone. You should add another module in Spring MVC Server")
.organization(JHipsterModuleOrganization.builder().feature(SPRING_SERVER).addDependency(SPRING_BOOT).build())
.tags(SERVER_TAG, SPRING_TAG, SPRING_BOOT_TAG, MVC_TAG, WEB_TAG)
.factory(springBootMvc::buildEmptyModule);
Expand Down Expand Up @@ -61,6 +61,6 @@ private JHipsterModulePropertiesDefinition properties() {
}

private JHipsterModuleOrganization mvcServerOrganization() {
return JHipsterModuleOrganization.builder().feature(SPRING_MVC_SERVER).addDependency(SPRING_BOOT_MVC).build();
return JHipsterModuleOrganization.builder().feature(SPRING_MVC_SERVER).addDependency(SPRING_BOOT_MVC_EMPTY).build();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ class SpringBootWebfluxModuleConfiguration {
JHipsterModuleResource springBootWebfluxModule(SpringBootWebfluxApplicationService webflux) {
return JHipsterModuleResource
.builder()
.slug(SPRING_BOOT_WEBFLUX)
.slug(SPRING_BOOT_WEBFLUX_EMPTY)
.propertiesDefinition(properties())
.apiDoc("Spring Boot - Webflux", "Add Spring Boot Webflux")
.apiDoc("Spring Boot - Webflux", "Add Spring Boot Webflux Netty")
.organization(JHipsterModuleOrganization.builder().feature(SPRING_SERVER).addDependency(SPRING_BOOT).build())
.tags("server", "webflux")
.tags("server", "webflux", "netty")
.factory(webflux::buildEmptyModule);
}

Expand All @@ -31,8 +31,8 @@ JHipsterModuleResource springBootWebfluxNettyModule(SpringBootWebfluxApplication
.builder()
.slug(SPRING_BOOT_WEBFLUX_NETTY)
.propertiesDefinition(properties())
.apiDoc("Spring Boot - Webflux", "Add Spring Boot Webflux with Netty")
.organization(JHipsterModuleOrganization.builder().addDependency(SPRING_BOOT_WEBFLUX).build())
.apiDoc("Spring Boot - Webflux", "Empty module: do not use alone. You should add module Spring Boot Webflux Netty")
.organization(JHipsterModuleOrganization.builder().addDependency(SPRING_BOOT_WEBFLUX_EMPTY).build())
.tags("server", "webflux")
.factory(webflux::buildNettyModule);
}
Expand Down
12 changes: 6 additions & 6 deletions src/test/features/git-info.feature
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ Feature: Git Information module

Scenario: Should inject Git Information into Spring
When I apply modules to default project
| maven-java |
| spring-boot |
| spring-boot-mvc |
| spring-boot-tomcat |
| spring-boot-actuator |
| git-information |
| maven-java |
| spring-boot |
| spring-boot-mvc-empty |
| spring-boot-tomcat |
| spring-boot-actuator |
| git-information |
Then I should have "<artifactId>git-commit-id-maven-plugin</artifactId>" in "pom.xml"
10 changes: 5 additions & 5 deletions src/test/features/spring-mvc.feature
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,16 @@ Feature: Spring MVC

Scenario: Should apply spring mvc tomcat module
When I apply modules to default project
| maven-java |
| spring-boot |
| spring-boot-mvc |
| spring-boot-tomcat |
| maven-java |
| spring-boot |
| spring-boot-mvc-empty |
| spring-boot-tomcat |
Then I should have "<artifactId>spring-boot-starter-web</artifactId>" in "pom.xml"

Scenario: Should apply spring mvc undertow module
When I apply modules to default project
| maven-java |
| spring-boot |
| spring-boot-mvc |
| spring-boot-mvc-empty |
| spring-boot-undertow |
Then I should have "<artifactId>spring-boot-starter-undertow</artifactId>" in "pom.xml"
2 changes: 1 addition & 1 deletion src/test/features/webflux.feature
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Feature: Webflux module
When I apply modules to default project
| maven-java |
| spring-boot |
| spring-boot-webflux |
| spring-boot-webflux-empty |
| spring-boot-webflux-netty |
Then I should have "<artifactId>spring-boot-starter-webflux</artifactId>" in "pom.xml"
Then I should have files in "src/main/java/tech/jhipster/chips/technical/infrastructure/primary/exception/"
Expand Down