asciidisco / grunt-qunit-istanbul

Run QUnit unit tests in a headless PhantomJS instance & generate some nice code coverage metrics using Istanbul.
MIT License
33 stars 21 forks source link

Problem with coverage HTML files' references, since version 0.5.0 (and 0.6.0) #51

Closed Lipata closed 8 years ago

Lipata commented 8 years ago

Hello.

Since I have updated grunt-qunit-istanbul to version 0.5.0 (I'm using also grunt-istanbul 0.6.0) the HTML coverage reports are having wrong references to the resource files it needs (prettify.css and base.css) as well as the coverage reports are generated inside the folder of the js files that needs instrumentatation and not in the configured folder. Here is my configuration:

coverage: {
    src: grunt.file.readJSON('config/all/instrument.json').config,
    instrumentedFiles: "tests/temp",
    htmlReport: "tests/coverageReport",
    jsonSummaryReport: "tests/coverageReportJSON",
    disposeCollector: true,
    reportOnFail: true,
    linesThresholdPct: 85,
    statementsThresholdPct: 85,
    functionsThresholdPct: 85,
    branchesThresholdPct: 85
},

where the src files are relative paths and looks like this: ....\Source\ClientUI\js\modules. The generated coverage HTML reports goes to that folder instead to the tests/coverageReport folder. Inside the report the references are:

 <link rel="stylesheet" href="../../../../../../../../../../prettify.css">
 <link rel="stylesheet" href="../../../../../../../../../../base.css">

This is working with version 0.4.5, but I cannot use it, cause version 0.5.0 is containing a fix that I've made and it's important for me.

I'm debugging the module and trying to understand what the problem could be, but if you have something in mind, what was regressed I will be grateful.

Thank you!

asciidisco commented 8 years ago

Hey,

sorry for the late reply & unfortunately I´m not able to help with this atm. due to some personal reasons. I´d more or less need to mark anything I have in the Open Source space as unmaintained now :(

I´m really sorry about this, but if you do find a fix, I can give you contribution & publish rights, so that you´re able to put out a new stable version. I´m afraid that this is the only thing I can do right now. I´m really, really sorry.

Cheers Sebastian

Lipata commented 8 years ago

No problem, Sebastian. It is a very useful plugin and I want to thank you for that. If I have a time to contribute to the plug-in, I will write you.

Regards.

Lipata commented 8 years ago

Not a problem in the module.