-
Notifications
You must be signed in to change notification settings - Fork 301
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
Support condition to check how many classes have matched #83
Conversation
RandomClassesSyntaxTest is failing, working on it. |
Thanks for your proposal!! 😃
Which already brings me to my suggestions
What do you think? If you don't have the time to implement the predicate version, I can also merge your PR and add that myself, so don't feel pressured!! Anyway, let me know if you need any help with the |
Thx. I will change wording, yours is much better, and create predicated version (mine was just to show the way :-) ). I will try to do my best with that Random test or ping you with questions later. |
changes done, pls take a look ;] |
0df1cf5
to
23aa37e
Compare
Thanks for the update!! First of all, can you do me one big favor and sign off your commits? -> https://github.com/TNG/ArchUnit/blob/master/CONTRIBUTING.md#commits If worse comes to worse, you can just squash your commits into one and do I didn't even expect you to write all those Some comments:
I hope you're not demotivated by another round of remarks!! I really appreciate your support 😃 |
Sure, no problem i will fix all the issues :-) . I am happy to help - I like and use you project. |
Signed-off-by: Ivo Smid <ivo.smid@gmail.com>
fixed, squashed and signed :] pls fix that random test, i have idea how to fix it but from my perspective it looks like that fix is somewhere in a singleParameterProviders, but i am not sure :] ... you will be faster |
…iling because the predicate for containNumberOfElements(..) was accidentally evaluated inversely. Now that this is fixed, the original code works just fine and the test passes again. Issue: TNG#83 Signed-off-by: Peter Gafert <peter.gafert@tngtech.com>
…escription, not the whole toString() of JavaClasses Issue: TNG#83 Signed-off-by: Peter Gafert <peter.gafert@tngtech.com>
Issue: TNG#83 Signed-off-by: Peter Gafert <peter.gafert@tngtech.com>
Thanks a lot for your contribution 😃 |
Oh, I take it back, guess it takes some more work 😉 Gonna fix it real quick... |
…this test, if the check passes or fails. The scope of this test is just * does the description match the expected description * can the created rule be evaluated and checked without any unexpected exception (NPE or similar) If the description matches, the rule can be evaluated, and the check either passes or throws an AssertionError, we're fine here Issue: TNG#83 Signed-off-by: Peter Gafert <peter.gafert@tngtech.com>
The problem was, that so far all rules evaluate okay for a set of 0 elements. With your addition
will fail for 0 imported classes, since the rule want that In the end, it is irrelevant to really check the rule for this test though. The intention right from the beginning was, to validate the description of various rule combinations and ensure, that no weird exceptions are thrown when evaluating / checking the created rule. So I've just relaxed the |
ahh, I see ... nice changes. Thx for merging :-) |
No prob, thx for your contribution 😄 |
…iling because the predicate for containNumberOfElements(..) was accidentally evaluated inversely. Now that this is fixed, the original code works just fine and the test passes again. Issue: #83 Signed-off-by: Peter Gafert <peter.gafert@tngtech.com>
…escription, not the whole toString() of JavaClasses Issue: #83 Signed-off-by: Peter Gafert <peter.gafert@tngtech.com>
Issue: #83 Signed-off-by: Peter Gafert <peter.gafert@tngtech.com>
…this test, if the check passes or fails. The scope of this test is just * does the description match the expected description * can the created rule be evaluated and checked without any unexpected exception (NPE or similar) If the description matches, the rule can be evaluated, and the check either passes or throws an AssertionError, we're fine here Issue: #83 Signed-off-by: Peter Gafert <peter.gafert@tngtech.com>
Support condition to check how many classes have matched
Hi,
pls take a look this proposal. I did not find rule that I can use to match how many classes has been matched to detect if state of code changed dramatically.
To have something similar to following code snippet.
I am not sure about DSL wording.
Thx
Ivos