Reports being generated in separate karate_report folder for each test runner

rochitsen

I just upgraded to version 1.0.1 of Karate from 0.9.6. Earlier all karate cucumber format .json reports were generated in a single folder: target/surefire-reports.

After the upgrade I can see that for each test runner which uses Runner.path builder to run a test feature file with outputCucumberJson(true) is creating the json file in folder's that have a number suffixed. eg, I have folders in target like:

karate_reports
karate_reports_162988888
karate_reports_162988777

Because of this the jenkins cucumber plugin that was working previously does not find the .json files. I have tried clearing the field JSON Reports Path in jenkins cucumber plugin so it scans the whole directory for json files but it does not work.

Any ideas what is going on? Can we still get all json files created in single folder when tests run via maven?

Also I tried setting the reportDir in the Runner.path builder but I still get multiple folders with suffixed numbers.

Help appreciated.

Peter Thomas

Yes there is a configuration setting called: backupReportDir() which you can set to false.

And next time, please try the RC releases earlier so that you can avoid these kinds of surprises and also alert us if we un-intentionally make breaking changes.

Finally, we do not recommend multiple test-runners in CI, you should have only one, and within that you can "select" different folder hierarchies or individual feature files to compose into a "suite".

There are good reasons for this:

  • the start and end time will be calculated correctly
  • the report aggregation of tags will work correctly
  • parallel execution of your entire suite will be optimized

Yes some of the above points assume you use the Karate HTML reports instead of the CI, JUnit or 3rd-party Cucumber reports. But this is the best practice, and the Karate reports are what we will focus on in the long term.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

How to generate cucumber reports not using a test runner

Karate API - How to read Json file from /src/test/resources folder using Junit runner?

Display <textarea> on each content that is being generated dynamically

How can I control how many JUnit5 Test Instances are going to be generated in Runtime and apply separate ParameterResolver to each of the instance

How to save generated pdf in project folder Node Jasper Reports?

Cypress Test-Runner: Hide detailed messages, instead of being expanded?

How to keep test generated sources out of the generated sources target folder

In test runner cannot see tests in newly created folder - cypress

Post-process bazel test command generated reports

nextflow: avoid work directory being generated despite output folder

Composer Private Repository .git-folder keeps being generated

Howto add another test source folder to Maven and compile it to a separate folder?

Reportviewer showing "Report is being generated" endlessly .net

Allure empty report being generated using Karma

AWS Device Farm.How can i save the custom report being generated after the test case into my local space

How to create separate in memory database for each test?

Run each JUnit Test with a Separate ClassLoader (no, really)

Running each JUnit test in a separate JVM in Eclipse?

Maven Verify Starting and Stopping the Spring Test Runner on Each class

How to separate output for each command generated by a bash file?

Angular karma code coverage report folder not generated

Cypress-testrail-reporter creating separate test runs for each test

How to create a jar with Maven that includes dependencies in a separate folder for each dependency

Deleting multiple identically named files each in separate folder

How to zip each folder in the directory into a separate .zip archive in python?

How to individually rename the files in each separate folder in a batch file

How to create a separate file inside each folder using pathlib in python?

making output files being created in each folder after parallel running

Report not being generated with Maven-Surefire-Report plugin