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

Build failure on project common-utils: groups/excludedGroups require TestNG or JUnit48+ on project test classpath #205

Open
landon9720 opened this issue Jun 4, 2019 · 7 comments

Comments

@landon9720
Copy link

On the master branch:

mvn install
...
[INFO] Reactor Summary for common 5.4.0-SNAPSHOT:
[INFO] 
[INFO] assembly-plugin-boilerplate ........................ SUCCESS [  0.442 s]
[INFO] Build Tools ........................................ SUCCESS [  0.358 s]
[INFO] common ............................................. SUCCESS [  1.048 s]
[INFO] utils .............................................. FAILURE [  0.620 s]
[INFO] metrics ............................................ SKIPPED
[INFO] config ............................................. SKIPPED
[INFO] common-logging ..................................... SKIPPED
[INFO] confluent-log4j-extensions ......................... SKIPPED
[INFO] confluent-log4j2-extensions ........................ SKIPPED
[INFO] package ............................................ SKIPPED
[INFO] Common ............................................. SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  2.721 s
[INFO] Finished at: 2019-06-04T15:12:11-07:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.21.0:test (default-test) on project common-utils: groups/excludedGroups require TestNG or JUnit48+ on project test classpath -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[ERROR] 
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <goals> -rf :common-utils

I have successfully built Kafka with ./gradlew installAll. Any troubleshooting tips?

@H1ght0wer1
Copy link

How did you manage to solve this problem? I also faced with it

@Kaurgurjot
Copy link

I am also facing the same issue can someone tell me how to resolve it?

@anhtv08
Copy link

anhtv08 commented Apr 28, 2020

I am also facing similar issue.
``[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.21.0:test (default-test) on project dtp-loft-tests: groups/excludedGroups require TestNG or JUnit48+ on project test classpath -> [Help 1]
[ERROR]

@NicolasMilligan
Copy link

NicolasMilligan commented Apr 29, 2020

@Kaurgurjot @anhtv08 I was able to get around this error by adding junit as a dependency in pom.xml to include it in my project like so

<dependency>
    <groupId>junit</groupId>
    <artifactId>junit</artifactId>
    <version>4.12</version>
    <scope>test</scope>
</dependency>

however this was in the context of smaller avro registry maven project I'm getting up and running and not related to this common-utils project.

Not sure if this is the valid solution but thought I'd share how I got through it!

@plumstone
Copy link

If you're using junit 5, the addition of the following dependency should solve the problem.

<dependency>
    <groupId>org.junit.jupiter</groupId>
    <artifactId>junit-jupiter-engine</artifactId>
    <version>5.7.0</version>
    <scope>test</scope>
</dependency>

@Dedmikash
Copy link

Just had same problem, one module failed on build.
It hasn't any tests in it, but has empty src/test/java folder with some empty packages and empty src/test/resources.
I completely removed src/test folder, now build is successful.

@arianapaz
Copy link

If you delete the target folder it works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants