Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The rule API should not only offer checks for accesses, but also for more generic dependencies in any way #69

Closed
codecholeric opened this issue May 17, 2018 · 0 comments

Comments

@codecholeric
Copy link
Collaborator

The most typical violations of components / layers can be caught by using a rule like

noClasses().that()...should().accessClassesThat()...

However, there are different types of dependencies, that are not caught by this (annotations, declared fields that are never accessed, etc.). While it is possible to check for this with several rules, the rule API should offer an easy and extensive way to check for this. Proposal:

noClasses().that()...should().dependOnClassesThat()...

And likewise, it should be possible to check the other way around

classes().that()...should().onlyHaveDepedentClassesThat()...

I.e. the last rule checks that all classes depending on this class should satisfy some condition.

codecholeric added a commit that referenced this issue Aug 15, 2018
Issue: #69
Signed-off-by: Peter Gafert <peter.gafert@tngtech.com>
codecholeric added a commit that referenced this issue Aug 15, 2018
Issue: #69
Signed-off-by: Peter Gafert <peter.gafert@tngtech.com>
codecholeric added a commit that referenced this issue Aug 15, 2018
Issue: #69
Signed-off-by: Peter Gafert <peter.gafert@tngtech.com>
@codecholeric codecholeric added this to the 0.9.0 milestone Aug 19, 2018
codecholeric added a commit that referenced this issue Feb 21, 2021
Issue: #69
Signed-off-by: Peter Gafert <peter.gafert@tngtech.com>
codecholeric added a commit that referenced this issue Feb 21, 2021
Issue: #69
Signed-off-by: Peter Gafert <peter.gafert@tngtech.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant