-
-
Notifications
You must be signed in to change notification settings - Fork 15
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
Support reporters #10
Conversation
Signed-off-by: Matteo Collina <hello@matteocollina.com>
Signed-off-by: Matteo Collina <hello@matteocollina.com>
Signed-off-by: Matteo Collina <hello@matteocollina.com>
@mcollina nice project! |
Really nice! I'll take a look and see if I can integrate it. |
try { | ||
res = fileURLToPath(new URL(file)) | ||
} catch (err) { | ||
if (err.code === 'ERR_INVALID_FILE_URL_PATH') { | ||
res = fileURLToPath(new URL(file.replace('file:///', 'file://'))) | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think your assesment is correct here, my understanding is that the URL that failed to be converted to path is file:///foo/test/add.test.ts
, which indeed does not make sense on Windows. But that's a value constructed in your tests, not one generated by the test runner IIUC.
try { | |
res = fileURLToPath(new URL(file)) | |
} catch (err) { | |
if (err.code === 'ERR_INVALID_FILE_URL_PATH') { | |
res = fileURLToPath(new URL(file.replace('file:///', 'file://'))) | |
} | |
} | |
res = fileURLToPath(file) |
I'll try to send a PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was failing with a Windows path.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No description provided.