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

Update AVA and enable testing on Node 14 #68

Merged
merged 8 commits into from
Sep 29, 2020
Merged

Update AVA and enable testing on Node 14 #68

merged 8 commits into from
Sep 29, 2020

Conversation

fregante
Copy link
Collaborator

@fregante fregante commented Sep 8, 2020

Based on #67

Blocked by avajs/babel#13 and especially babel/babel#6737

This PR won't be merged. I think the only way to support this mess is to pre-bundle the test files like I did in Refined GitHub: refined-github/refined-github#3206

The problematic combination is:

  • JSX in test files
  • type: module in main module

Babel is needed to support JSX in test files, but there's no way to then import ./index.js since it's a type: module that can't be require'd


Note: The tests on master currently already work with AVA@3 as soon as I drop type: module.

@fregante
Copy link
Collaborator Author

fregante commented Sep 8, 2020

Possible alternative solution: look into Jest

@fregante fregante changed the title Unsuccessfully attempt moving tests to Node 14 / AVA 3 Update AVA and enable testing on Node 14 Sep 29, 2020
@fregante fregante marked this pull request as ready for review September 29, 2020 00:38
@fregante fregante merged commit c854781 into master Sep 29, 2020
@fregante fregante deleted the node-esm branch September 29, 2020 00:38
@fregante
Copy link
Collaborator Author

I resolved by using Rollup (which was already there) to create a CJS bundle and test against that in a folder marked as type: "commonjs"

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

Successfully merging this pull request may close these issues.

1 participant