Skip to content

Commit

Permalink
test: introduce a new package spi
Browse files Browse the repository at this point in the history
This package contains interfaces of services that can be used in core.
In Hexagonal Architecture, they match to components on the right side.
  • Loading branch information
jgiovaresco committed Mar 28, 2024
1 parent 0d53650 commit b049403
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
Expand Up @@ -40,6 +40,7 @@ public class AbstractApimArchitectureTest {
public final String CRUD_SERVICE_PACKAGE = "crud_service";
public final String QUERY_SERVICE_PACKAGE = "query_service";
public final String DOMAIN_SERVICE_PACKAGE = "domain_service";
public final String SERVICE_PROVIDER_PACKAGE = "spi";
public final String NOTIFICATION_PACKAGE = "notification";
public final String ADAPTER_PACKAGE = "adapter";
public final String MODEL_PACKAGE = "model";
Expand Down
Expand Up @@ -48,7 +48,8 @@ public void should_respect_onion_architecture() {
.domainServices(
"io.gravitee.apim.core.*." + CRUD_SERVICE_PACKAGE + "..",
"io.gravitee.apim.core.*." + QUERY_SERVICE_PACKAGE + "..",
"io.gravitee.apim.core.*." + DOMAIN_SERVICE_PACKAGE + ".."
"io.gravitee.apim.core.*." + DOMAIN_SERVICE_PACKAGE + "..",
"io.gravitee.apim.core.*." + SERVICE_PROVIDER_PACKAGE + ".."
)
.applicationServices(anyPackageThatContains(CORE_PACKAGE + ".*." + USECASE_PACKAGE))
.adapter("infra", anyPackageThatContains(INFRA_PACKAGE), anyPackageThatContains("io.gravitee.rest.api.service"))
Expand Down

0 comments on commit b049403

Please sign in to comment.