-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Introduce InvocationInterceptor extension API #1852
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for working on this and submitting the PR!
I think this is coming along very nicely.
I haven't reviewed it yet in an IDE, so my comments here are based solely on what I can see in the browser.
junit-jupiter-api/src/main/java/org/junit/jupiter/api/extension/InvocationInterceptor.java
Outdated
Show resolved
Hide resolved
junit-jupiter-api/src/main/java/org/junit/jupiter/api/extension/InvocationInterceptor.java
Outdated
Show resolved
Hide resolved
junit-jupiter-api/src/main/java/org/junit/jupiter/api/extension/InvocationInterceptor.java
Show resolved
Hide resolved
...iter-engine/src/main/java/org/junit/jupiter/engine/descriptor/TestFactoryTestDescriptor.java
Outdated
Show resolved
Hide resolved
...piter-engine/src/main/java/org/junit/jupiter/engine/descriptor/TestMethodTestDescriptor.java
Outdated
Show resolved
Hide resolved
...t-jupiter-api/src/main/java/org/junit/jupiter/api/extension/ReflectiveInvocationContext.java
Show resolved
Hide resolved
junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/execution/ExecutableInvoker.java
Outdated
Show resolved
Hide resolved
...iter-engine/src/test/java/org/junit/jupiter/engine/extension/InvocationInterceptorTests.java
Outdated
Show resolved
Hide resolved
...iter-engine/src/test/java/org/junit/jupiter/engine/extension/InvocationInterceptorTests.java
Outdated
Show resolved
Hide resolved
FYI The JaCoCo issue was caused by |
Ahhhh.... nice detective work! And... I saw your commit to fix it... exactly like I'd have done. 😉 So glad they added |
But... wait! Didn't Speaking of that, @junit-team/junit-lambda, why does |
I was wondering that, too. It looks like it had |
@geo-m Do you remember? |
That would explain why the same JaCoCo problem appeared and then magically disappeared back then. In any case, I think we should make those methods I realize I'm hijacking this PR on this topic now, but... @junit-team/junit-lambda, any objections to making that change? |
None from me. |
Good, 'cause I've already made the change on my machine. 😇 |
Codecov Report
@@ Coverage Diff @@
## master #1852 +/- ##
============================================
- Coverage 91.55% 91.41% -0.15%
- Complexity 4097 4119 +22
============================================
Files 344 348 +4
Lines 9773 9876 +103
Branches 798 801 +3
============================================
+ Hits 8948 9028 +80
- Misses 630 651 +21
- Partials 195 197 +2
Continue to review full report at Codecov.
|
The new extension API allows intercepting the invocation of test class constructors, lifecycle methods, testable methods, and dynamic tests. It validates that an invocation is asked to proceed exactly once. The user guide is updated with an example that executes all test methods in Swing's EDT. Resolves #157.
3fc8eb5
to
bb79507
Compare
Overview
The new extension API allows intercepting the invocation of test class
constructors, lifecycle methods, testable methods, and dynamic tests.
It validates that an invocation is asked to proceed exactly once. The
user guide is updated with an example that executes all test methods in
Swing's EDT.
Resolves #157.
I hereby agree to the terms of the JUnit Contributor License Agreement.
Definition of Done
@API
annotations