Class AbstractTacticArchUnitTest


  • public abstract class AbstractTacticArchUnitTest
    extends java.lang.Object
    An abstract test class that can be extended in order to execute all our ArchRules for a single Bounded Context. This test is based on the jMolecules annotations. In case you work with other annotations, you have to implement your test manually.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected com.tngtech.archunit.core.domain.JavaClasses classes  
      protected org.contextmapper.dsl.contextMappingDSL.BoundedContext context  
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      protected abstract java.lang.String getBoundedContextName()
      Implement this method to define the Bounded Context name.
      protected abstract java.lang.String getCMLFilePath()
      Implement this method to define against which CML file you want to test.
      protected abstract java.lang.String getJavaPackageName2Test()
      Implement this method to defined the java package within which you want to test.
      protected com.tngtech.archunit.core.domain.JavaClasses importClasses()
      Override this method to change class import behavior.
      protected void setup()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • context

        protected org.contextmapper.dsl.contextMappingDSL.BoundedContext context
      • classes

        protected com.tngtech.archunit.core.domain.JavaClasses classes
    • Constructor Detail

      • AbstractTacticArchUnitTest

        public AbstractTacticArchUnitTest()
    • Method Detail

      • getBoundedContextName

        protected abstract java.lang.String getBoundedContextName()
        Implement this method to define the Bounded Context name.
      • getCMLFilePath

        protected abstract java.lang.String getCMLFilePath()
        Implement this method to define against which CML file you want to test.
      • getJavaPackageName2Test

        protected abstract java.lang.String getJavaPackageName2Test()
        Implement this method to defined the java package within which you want to test.
      • setup

        @BeforeEach
        protected void setup()
      • importClasses

        protected com.tngtech.archunit.core.domain.JavaClasses importClasses()
        Override this method to change class import behavior.