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

[TESTS] Make sure test end with ..Tests #9945

Closed
brwe opened this issue Mar 2, 2015 · 5 comments · Fixed by #9947
Closed

[TESTS] Make sure test end with ..Tests #9945

brwe opened this issue Mar 2, 2015 · 5 comments · Fixed by #9947
Assignees
Labels
>bug >test Issues or PRs that are addressing/adding tests v1.5.0 v2.0.0-beta1

Comments

@brwe
Copy link
Contributor

brwe commented Mar 2, 2015

We currently filter test classes by suffix Test or Tests (https://github.com/elasticsearch/elasticsearch/blob/master/pom.xml#L495), but there is no automation in place to guarantee that test classes actually end with this suffix. As a result, some tests did not run on CI without anyone noticing (see for example 600cb88). Would be great if we had some automation that checks that classes that derive from Test classes like ElasticsearchIntegrationTest have the right suffix.

@javanna
Copy link
Member

javanna commented Mar 2, 2015

+1 I think we should rather take ElasticsearchTestCase as the base class though.

@martijnvg
Copy link
Member

Or if a test class has '@test' then the class name must end with *Test

@javanna
Copy link
Member

javanna commented Mar 2, 2015

@martijnvg I'm afraid we don't use the @Test annotation consistently though... we better look also for method names that start with test if we take that approach.

@martijnvg
Copy link
Member

Yes, we take this approach we should also look for method names starting with test. I think we either should the test method name consistently or the test annotation, but that is a different discussion.

s1monw added a commit to s1monw/elasticsearch that referenced this issue Mar 2, 2015
This commit adds a simple testcase that ensures all our tests end with the right naming.

Closes elastic#9945
s1monw added a commit to s1monw/elasticsearch that referenced this issue Mar 2, 2015
This commit adds a simple testcase that ensures all our tests end with the right naming.

Closes elastic#9945
@s1monw s1monw added v2.0.0-beta1 v1.5.0 >bug >test Issues or PRs that are addressing/adding tests labels Mar 2, 2015
@s1monw
Copy link
Contributor

s1monw commented Mar 2, 2015

thanks so much @brwe for finding this... das glück des tüchtigen...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>bug >test Issues or PRs that are addressing/adding tests v1.5.0 v2.0.0-beta1
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants