 1 class DependencyRuleTests {
 2
 3   @Test
 4   void validateHexagonalArchitecture() {
 5     HexagonalArchitecture.basePackage("buckpal")
 6         .withApplicationLayer("application")
 7             .domainModel("domain.model")
 8             .services("domain.service")
 9             .incomingPorts("port.in")
10             .outgoingPorts("port.out")
11             .and()
12         .withAdaptersLayer("adapter")
13             .incoming("in.web")
14             .outgoing("out.persistence")
15             .and()
16         .withConfiguration("configuration")
17         .check(new ClassFileImporter()
18             .importPackages("buckpal.."));
19   }
20 }
