-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
IncludeExcludeCategory should accept many categories + configurable #461
Conversation
@@ -16,13 +11,60 @@ | |||
import org.junit.runners.model.InitializationError; | |||
import org.junit.runners.model.RunnerBuilder; | |||
|
|||
import java.lang.annotation.Retention; | |||
import java.lang.annotation.RetentionPolicy; | |||
import java.util.*; |
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.
JUnit style is never to import *.
ok, i will fix this. |
@dsaff
Is it fine? |
* -Dorg.junit.categories.excluded=com/Category3.java,com/Category4.java | ||
* </pre></blockquote> | ||
* <p> | ||
* Thus a class 'com.Category1' has file name 'com/Category1.java'. |
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.
Remind me again why you're suggesting using java file names?
because the So i wanted to be consistent with maven. Example of test class and properties in pom.xml: groupId: maven-surefire-plugin But we may change it if necessary. |
It looks like surefire already supports categories, and using class names, http://maven.apache.org/plugins/maven-surefire-plugin/examples/junit.html On Thu, Jul 19, 2012 at 3:54 PM, Tibor17 <
|
In passed, the groups was dedicated only to TestNG. Now also to JUnit. |
@dsaff |
* Note that, for now, annotating suites with {@code @Category} has no effect. | ||
* Categories must be annotated on the direct method or class. | ||
* | ||
* <p> | ||
* When filtering every individual test method to run, the child categories are |
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.
I'll be honest--I'm keep coming back to review this, and end up balking at this block of javadoc. I think we have to find a clearer way to express what's going on here in order to make it useful to users. Unfortunately, time is pretty tight for me, so it will be a while before I have time to make specific line-by-line suggestions.
I have two thoughts for moving forward:
- Copy the Javadoc into a Google doc for some collaborative editing as time allows--once we've iterated to a good point, we can copy back here.
- Ask on the [email protected] list for a collaborator that does have time to give this an edit with a critical eye.
Ideas?
@dsaff |
@dsaff this pull closed by some merge in a mistake :( Can be reopened? The changes are gone , but i have backup, so what should i do? Open a new pull? |
I'm sorry, I don't seem to be able to. Can you re-request? |
yes, i will re-request again, and i will let you know what changes i made to simplify javadoc. Your right, the user may really have millions of question in corner behavior -around @ignore and empty tests, etc. |
This pul request was created after I resolved conflicts with KentBeck:master.
This is the same #354 + #336 .
We discussed this feature in #142 and continued then in #354.