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

Set HTML report path based on build tool #319

Closed
hosszubalazs opened this issue Feb 9, 2018 · 7 comments
Closed

Set HTML report path based on build tool #319

hosszubalazs opened this issue Feb 9, 2018 · 7 comments
Assignees
Milestone

Comments

@hosszubalazs
Copy link

In KarateHtmlReporter.java the path of the created SureFire report is set in the following way:
File file = new File("target/surefire-reports/TEST-" + packageName + ".html");

This is incorrect in a Gradle environment. Build artifacts, like reports, are expected under the "build" folder, not "target". Running the tests creates a new folder, usually outside of source control rules or ignore settings.

Request:
HTML report should be created under a path specific to the build tool conventions, improving support for Gradle.

@ptrthomas
Copy link
Member

what's the best way to determine which tool is in operation ?

@KramKroc
Copy link
Contributor

Is this new in 0.7.0? One solution would be to pass the path in rather than hard coding?

@ptrthomas
Copy link
Member

@KramKroc kind of 0.6.2 onwards - just that I never realized gradle does its own thing. I'm hoping some gradle expert would know of e.g. some system property that we can look for etc.

@ptrthomas ptrthomas self-assigned this Feb 27, 2018
@ptrthomas ptrthomas added this to the v0.7.1 milestone Feb 27, 2018
@ptrthomas
Copy link
Member

if anyone is listening to this thread kindly try 0.7.0.1 (just released) and do confirm. this is damn near impossible to test in my environment. there's no way to get a local maven artifact used by a local gradle project it seems

@hosszubalazs
Copy link
Author

Hey @ptrthomas !

I have a Gradle integration:
0.7.0 : "target" folder is created containing "surefire-reports"
0.7.0.1 : no "target" folder, "build" contains "surefire-reports"

From my point of view, the fix works. Thanks a lot!
Solving this could help you in verifying Gradle stuff ;) --> #308

@ptrthomas
Copy link
Member

ah @hosszubalazs finally appears ! thanks for confirming :)

@ptrthomas
Copy link
Member

released 0.8.0

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

No branches or pull requests

3 participants