arch-unit-maven-plugin icon indicating copy to clipboard operation
arch-unit-maven-plugin copied to clipboard

Execute rule on the aggregator ('pom' packaging)

Open skylartd opened this issue 1 year ago • 1 comments

Summary

There is archunit test(Layering testing) that need to perform on 'pom' packaging but the default behavior of the plugin is skip 'pom' packaging by default.

Type of Issue

It is a :

  • [ ] bug
  • [x] request
  • [ ] question regarding the documentation

Motivation

I want to perform Archunit Layer Check using the plugin on many of our projects.

Current Behavior

The plugin will skip 'pom' packaging by default

Expected Behavior

The plugin configuration should provide a way to execute archunit check on 'pom' packaging and all its sub-module projects instead of just skipping it. For example we can provide a configuration in the applyOn like this.

<configurableRule>
    <rule>com.test.LayerTest</rule>
    <applyOn>
        <!-- can be "true" or "false" -->
        <aggregator>true</aggregator>
    </applyOn>

    <checks>
        <check>LAYER_CHECK</check>
    </checks>
</configurableRule>

skylartd avatar Nov 27 '23 08:11 skylartd

I've created 2 PRs (1 in core and 1 in the plugin), can you guys help me to take a look? https://github.com/societe-generale/arch-unit-build-plugin-core/pull/83 https://github.com/societe-generale/arch-unit-maven-plugin/pull/65

skylartd avatar Nov 27 '23 09:11 skylartd