Skip to content

@codecholeric codecholeric released this Jan 10, 2020 · 2 commits to release-0.13.0 since this release

Breaking Changes

  • While technically a very slim chance of really "breaking" anything, the log level of some details during the class file import has been reduced from DEBUG to TRACE (field, method, access and call details, ...) (see #291)

Enhancements

Core

  • Annotations and annotation parameters are now detected as dependencies. This could cause new findings when using the rules or library API. In particular JavaClass.getDirectDependencies{From/To}Self() will now also return Dependencies that originate from @FormerlyNotDetected or @Foo(someEnum = SomeEnumFormerlyNotDetected.FOO) or @Foo(bar = @Bar(type = SomeTypeFormerlyNotDetected.class)) (see #136; thanks a lot to @kosani)

Lang

  • Some rule API method parameter types were invariant instead of contravariant (effectively preventing a predicate for a super type to be passed). These methods should now be fixed (see #262)
  • The rules API now offers more methods to filter and assert the type of class declaration ("top level class", "nested class", "member class", "inner class", "anonymous class" and "local class") (see #207; many thanks to @rweisleder)

Library

  • FreezingArchRule by default now not only ignores line numbers, but also numbers after $ which effectively makes the ViolationStore resilient against changes in compiled lambda and anonymous class names (see #248; thanks a lot to @hankem)
  • LayeredArchitecture and OnionArchitecture now allow to configure optionalLayers(). In version 0.12.0 the behavior was made more strict, forbidding empty layers / parts of LayeredArchitecture and OnionArchitecture to prevent misconfiguration. This in turn unfortunately broke some valid use cases where empty / optional layers were in fact okay. In version 0.13.0 this is now completely configurable. By default it will still fail to prevent misconfiguration, but a switch of withOptionalLayers(true) or optionalLayer("Some Layer") will allow empty layers (and in turn empty parts of OnionArchitecture) (see #267 and #271; many thanks to @hankem)

JUnit

  • there is now a ArchUnit JUnit 5 aggregator POM, i.e. instead of two dependencies archunit-junit5-api and archunit-junit5-engine, it is now also possible to simply add a single dependency archunit-junit5 with scope test / testCompile. Compare the user guide (see #272; thanks a lot to @eddumelendez)
  • Dependency upgrades (see #292)
    • junit-platform-* from 1.5.1 to 1.5.2
    • junit4 from 4.12 to 4.13 (in case of problems with archunit-junit4 it should be possible to exclude the transitive dependency to JUnit 4.13 and replace it by a custom 4.12 one)

Further Acknowledgement

  • Many thanks to @Bananeweizen for fixing spelling and grammar mistakes in Javadoc / methods
Assets 2
You can’t perform that action at this time.