adamgruber / mochawesome-report-generator

Standalone mochawesome report generator. Just add test data.
MIT License
232 stars 89 forks source link

timestamp flag wont work #149

Closed noririco closed 3 years ago

noririco commented 3 years ago
marge ./e2e/reports/results/mochawesome.json --ts --inline -o ./e2e/reports/tests_report

//or

marge ./e2e/reports/results/mochawesome.json --timestamp --inline -o ./e2e/reports/tests_report

This will generate 1 html file: ./e2e/reports/tests_report.html

expected: ./e2e/reports/tests_report_TIMESTAMP.html

or something like that.

More info:

package.json

...
    "mochawesome": "^6.1.1",
    "mochawesome-merge": "^4.2.0",
    "mochawesome-report-generator": "^5.1.0",
..
adamgruber commented 3 years ago

I was able to reproduce this issue and it indeed seems to be a bug. A temporary workaround is to set the value to true like this:

marge ./e2e/reports/results/mochawesome.json --ts true --inline -o ./e2e/reports/tests_report
adamgruber commented 3 years ago

So this isn't actually a bug but the documentation around this feature was incorrect and has since been fixed. You MUST pass a string with this option for it to work. You may pass true and it will default to isoDateTime formatting.