Skip to content

c8 report doesn't work on Windows #41

Description

@weswigham
  • Version:
    3.2.1
  • Platform:
    Windows 10

c8 report always outputs an empty report block on windows, no matter what include or exclude options you do (or don't) provide. Looking at it, it looks like the coverage files being produced on windows have paths like file:///E:/Github/TypeScript/built/local/tsc.js, which c8 then shortens to /E:/Github/TypeScript/built/local/tsc.js internally, which I'm guessing don't glob match (anything) correctly inside test-exclude, since that's not how windows-style paths are typically rooted (though I'm not sure - that last bit's a guess, since I'm not too familiar with the package).

Activity

  1. fraxken commented on Nov 16, 2018

    @fraxken

    Hi,

    Same problem here on Windows 10. Deleting the last / fixed the problem on my project:

    v8ScriptCov.url = v8ScriptCov.url.replace(/^file:\/\/\//, '')

    Best Regards,
    Thomas

  2. added a commit that references this issue on Nov 21, 2018
    1330d57
  3. sliekens commented on Nov 24, 2018

    @sliekens

    Same problem, Windows 10 build 1809 (17763.134).

    The workaround I use right now involves enabling WSL, installing Ubuntu and then running c8 from a bash prompt.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions