Skip to content

Update README.md to junit-platform-console #2273

@jwheeler31

Description

@jwheeler31

Describe the bug
README.md is not correct for Gradle. The defined org.junit.platform.console.ConsoleLauncher is located in org.junit.platform:junit-platform-console:X.Y.Z.

To Reproduce
Steps to reproduce the behavior:

  1. Follow the steps for README.md#cucumber-junit-platform-engine
  2. Assume, incorrectly, that the only dependency needed is: org.junit.platform:junit-platform-launcher:X.Y.Z
  3. Run ./gradlew clean test
  4. Observe error:
> Task :consoleLauncherTest FAILED
Error: Could not find or load main class org.junit.platform.console.ConsoleLauncher
Caused by: java.lang.ClassNotFoundException: org.junit.platform.console.ConsoleLauncher

Expected behavior
Cucumber tests are executed.

Context & Motivation
In greenfielding an application, other individuals decided to use Kotest and Cucumber for the test stack. This walkthrough, while ultimately being extremely helpful, was incomplete in accomplishing the objective.

Screenshots

...
> Task :consoleLauncherTest FAILED
Error: Could not find or load main class org.junit.platform.console.ConsoleLauncher
Caused by: java.lang.ClassNotFoundException: org.junit.platform.console.ConsoleLauncher

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':consoleLauncherTest'.
> Process 'command '/Library/Java/JavaVirtualMachines/jdk-11.0.10.jdk/Contents/Home/bin/java'' finished with non-zero exit value 1
...

Your Environment

  • Versions used [e.g 5.0.0] 1.7.0
  • Operating System and version [e.g. * Operating System and version:] Mac OS X 10.15.7 (Catalina) x86_64
  • Build tool [e.g. Apache Maven 3.6.0]
    • Gradle: 6.8.3
    • Kotlin: 1.4.30
    • JVM: 11.0.10 (Oracle Corporation 11.0.10+8-LTS-162)

Additional context
No context, just requesting that the document be updated to reflect the need for org.junit.platform:junit-platform-console:1.7.0.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions