-
-
Notifications
You must be signed in to change notification settings - Fork 375
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
Tests for Default template do not work #892
Comments
I could trace it to Not sure why it's only trying to resolve json file. I tried changing it to .js & it worked. |
I can confirm. 😞 Looks like it needs a newer Jest..
If I give the right version, it fails with:
|
It was working in preactjs-templates/default@44d5aac Using the presets from package.json, copying the |
it works with jest updated to latest version in package.json |
@scythianfuego Great detective skills! Can you file a PR? I'd be happy to merge it 👍 |
I needed some more steps to get tests running with jest 24.9.0. Update
|
Well, I've created a pull request for templates repo with @andreek fixes As for style.css I think we should add 'css' to moduleFileExtensions in jest config here
as mentioned here https://jestjs.io/docs/en/configuration#modulefileextensions-array-string but as now it will create a dependency to preact-cli release that doesn't yet exist |
Closing this since the tests in the default template were fixed in preactjs-templates/default#31 |
** I'd post this in the templates repo but there is no issue section available.
Do you want to request a feature or report a bug?
Bug
What is the current behaviour?
The
npm test
command fails for apps produced using thedefault
templateIf the current behaviour is a bug, please provide the steps to reproduce.
npm i -g preact-cli@3.0.0-rc.1
preact create default foobar
npm test
output:
What is the expected behaviour?
Should run sample tests successfully.
Please mention other relevant information.
Even if I use the
--config
flag to point to thejest-preset-preact
config file directly, it fails.The text was updated successfully, but these errors were encountered: