You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ArchUnit tests written in the following manner are not picked up by continuous testing:
@AnalyzeClasses(packages = "com.myapp")
publicclassArchitectureTest {
// ArchRules can just be declared as static fields and will be evaluated@ArchTestpublicstaticfinalArchRulerule1 = classes().should()...
@ArchTestpublicstaticfinalArchRulerule2 = classes().should()...
@ArchTestpublicstaticvoidrule3(JavaClassesclasses) {
// The runner also understands static methods with a single JavaClasses argument// reusing the cached classes
}
}
q_ct-archunit.zip contains a single AU test and continous testing displays: "No tests found". mvn test does execute the test (and it fails deliberately).
Description
ArchUnit tests written in the following manner are not picked up by continuous testing:
(taken from https://www.archunit.org/userguide/html/000_Index.html#_junit_support)
q_ct-archunit.zip contains a single AU test and continous testing displays: "No tests found".
mvn test
does execute the test (and it fails deliberately).I played around with
JunitTestRunner
and with a few additional lines the class is discovered, but somewhere in the depths of JUnit something doesn't work as expected and theTestPlan
seems to be empty.I also tried loading AU parent-first, because there is a special engine: https://github.com/TNG/ArchUnit/blob/main/archunit-junit/junit5/engine/src/main/java/com/tngtech/archunit/junit/ArchUnitTestEngine.java
But no luck so far.
Implementation ideas
No response
The text was updated successfully, but these errors were encountered: