[BAEL-4381] Intro to ArchUnit
Package typo
This commit is contained in:
parent
2355ccfb5e
commit
751c60fb71
@ -1,7 +1,7 @@
|
|||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
package com.baldung.archunit.smurfs.persistence;
|
package com.baeldung.archunit.smurfs.persistence;
|
||||||
|
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@ -9,7 +9,7 @@ import java.util.Map;
|
|||||||
import java.util.Optional;
|
import java.util.Optional;
|
||||||
import java.util.TreeMap;
|
import java.util.TreeMap;
|
||||||
|
|
||||||
import com.baldung.archunit.smurfs.persistence.domain.Smurf;
|
import com.baeldung.archunit.smurfs.persistence.domain.Smurf;
|
||||||
|
|
||||||
import static java.util.stream.Collectors.toList;
|
import static java.util.stream.Collectors.toList;
|
||||||
|
|
@ -1,7 +1,7 @@
|
|||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
package com.baldung.archunit.smurfs.persistence.domain;
|
package com.baeldung.archunit.smurfs.persistence.domain;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Philippe
|
* @author Philippe
|
@ -1,4 +1,4 @@
|
|||||||
package com.baldung.archunit.smurfs.presentation;
|
package com.baeldung.archunit.smurfs.presentation;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
@ -7,8 +7,8 @@ import org.springframework.web.bind.annotation.GetMapping;
|
|||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
import com.baldung.archunit.smurfs.service.SmurfsService;
|
import com.baeldung.archunit.smurfs.service.SmurfsService;
|
||||||
import com.baldung.archunit.smurfs.service.dto.SmurfDTO;
|
import com.baeldung.archunit.smurfs.service.dto.SmurfDTO;
|
||||||
|
|
||||||
@RequestMapping(value = "/smurfs", produces = MediaType.APPLICATION_JSON_UTF8_VALUE)
|
@RequestMapping(value = "/smurfs", produces = MediaType.APPLICATION_JSON_UTF8_VALUE)
|
||||||
@RestController
|
@RestController
|
@ -1,16 +1,16 @@
|
|||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
package com.baldung.archunit.smurfs.service;
|
package com.baeldung.archunit.smurfs.service;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
import org.springframework.stereotype.Component;
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
import com.baldung.archunit.smurfs.persistence.SmurfsRepository;
|
import com.baeldung.archunit.smurfs.persistence.SmurfsRepository;
|
||||||
import com.baldung.archunit.smurfs.persistence.domain.Smurf;
|
import com.baeldung.archunit.smurfs.persistence.domain.Smurf;
|
||||||
import com.baldung.archunit.smurfs.service.dto.SmurfDTO;
|
import com.baeldung.archunit.smurfs.service.dto.SmurfDTO;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Philippe
|
* @author Philippe
|
@ -1,9 +1,9 @@
|
|||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
package com.baldung.archunit.smurfs.service.dto;
|
package com.baeldung.archunit.smurfs.service.dto;
|
||||||
|
|
||||||
import com.baldung.archunit.smurfs.persistence.domain.Smurf;
|
import com.baeldung.archunit.smurfs.persistence.domain.Smurf;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Philippe
|
* @author Philippe
|
@ -25,7 +25,7 @@ public class SmurfsArchUnitTest {
|
|||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void givenPresentationLayerClasses_thenWrongCheckFails() {
|
public void givenPresentationLayerClasses_thenWrongCheckFails() {
|
||||||
JavaClasses jc = new ClassFileImporter().importPackages("com.baldung.archunit.smurfs");
|
JavaClasses jc = new ClassFileImporter().importPackages("com.baeldung.archunit.smurfs");
|
||||||
|
|
||||||
ArchRule r1 = classes()
|
ArchRule r1 = classes()
|
||||||
.that()
|
.that()
|
||||||
@ -40,7 +40,7 @@ public class SmurfsArchUnitTest {
|
|||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void givenPresentationLayerClasses_thenCheckWithFrameworkDependenciesSuccess() {
|
public void givenPresentationLayerClasses_thenCheckWithFrameworkDependenciesSuccess() {
|
||||||
JavaClasses jc = new ClassFileImporter().importPackages("com.baldung.archunit.smurfs");
|
JavaClasses jc = new ClassFileImporter().importPackages("com.baeldung.archunit.smurfs");
|
||||||
|
|
||||||
ArchRule r1 = classes()
|
ArchRule r1 = classes()
|
||||||
.that()
|
.that()
|
||||||
@ -54,7 +54,7 @@ public class SmurfsArchUnitTest {
|
|||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void givenPresentationLayerClasses_thenNoPersistenceLayerAccess() {
|
public void givenPresentationLayerClasses_thenNoPersistenceLayerAccess() {
|
||||||
JavaClasses jc = new ClassFileImporter().importPackages("com.baldung.archunit.smurfs");
|
JavaClasses jc = new ClassFileImporter().importPackages("com.baeldung.archunit.smurfs");
|
||||||
|
|
||||||
ArchRule r1 = noClasses()
|
ArchRule r1 = noClasses()
|
||||||
.that()
|
.that()
|
||||||
@ -69,7 +69,7 @@ public class SmurfsArchUnitTest {
|
|||||||
@Test
|
@Test
|
||||||
public void givenApplicationClasses_thenNoLayerViolationsShouldExist() {
|
public void givenApplicationClasses_thenNoLayerViolationsShouldExist() {
|
||||||
|
|
||||||
JavaClasses jc = new ClassFileImporter().importPackages("com.baldung.archunit.smurfs");
|
JavaClasses jc = new ClassFileImporter().importPackages("com.baeldung.archunit.smurfs");
|
||||||
|
|
||||||
LayeredArchitecture arch = layeredArchitecture()
|
LayeredArchitecture arch = layeredArchitecture()
|
||||||
// Define layers
|
// Define layers
|
||||||
|
Loading…
x
Reference in New Issue
Block a user