Skip to content
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

add tests ensuring import.meta.url paths succeed windows linux #30

Closed
iambumblehead opened this issue Aug 16, 2022 · 3 comments
Closed

Comments

@iambumblehead
Copy link
Owner

iambumblehead/esmock#114

@iambumblehead
Copy link
Owner Author

iambumblehead commented Aug 16, 2022

const pathModuleFull = resolvewith(modulePath, calleePath)

values from failing esmock test,

 {
  modulePath: 'D:\\a\\esmock\\esmock\\tests\\tests-source-map\\dist\\index.js',
  calleePath: '\\a\\esmock\\esmock\\tests\\tests-source-map\\src\\__tests__\\index.test.ts',
  pathModuleFull: null
}

values from passing test

{
  modulePath: '../index.js',
  calleePath: '/a/esmock/esmock/tests/tests-source-map/dist/__tests__/index.test.js',
  pathModuleFull: 'D:\\a\\esmock\\esmock\\tests\\tests-source-map\\dist\\index.js'
}

@iambumblehead
Copy link
Owner Author

maybe check for this pattern '\' eg, /\\\\/.test(path)

@iambumblehead
Copy link
Owner Author

this was resolved with #31

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant