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 to todays wasm-pack #151

Open
wants to merge 14 commits into
base: master
Choose a base branch
from
Open

Conversation

dns2utf8
Copy link

@dns2utf8 dns2utf8 commented Aug 4, 2019

No description provided.

fitzgen and others added 14 commits June 3, 2019 11:23
…/webpack-dev-server-3.5.1

Build(deps-dev): Bump webpack-dev-server from 3.3.1 to 3.5.1
…/webpack-4.33.0

Build(deps-dev): Bump webpack from 4.31.0 to 4.33.0
…/webpack-dev-server-3.7.1

Build(deps-dev): Bump webpack-dev-server from 3.5.1 to 3.7.1
Significant changes to clean things up and improve the user UX
@Pauan
Copy link
Contributor

Pauan commented Aug 4, 2019

I don't think this is quite correct.

A lot of apps are designed to be run in the browser, so running the tests in Node will fail.

@Pauan
Copy link
Contributor

Pauan commented Aug 4, 2019

Ideally this should be fixed in wasm-pack, so we can just run wasm-pack test and it will choose which runners to use at runtime, rather than needing to pass in flags.

@dns2utf8
Copy link
Author

dns2utf8 commented Aug 5, 2019

Well that might be true, however they decided to change the flag from --headless to --node for some reason unknown to me.

@Pauan
Copy link
Contributor

Pauan commented Aug 5, 2019

@dns2utf8 Where did you hear that?

@dns2utf8
Copy link
Author

dns2utf8 commented Aug 7, 2019

I got an error message when using the command:

$ wasm-pack test --headless
Error: Must specify at least one of `--node`, `--chrome`, `--firefox`, or `--safari`

@Pauan
Copy link
Contributor

Pauan commented Aug 8, 2019

@dns2utf8 Yes, that is correct, you must specify at least one of those options, like so:

wasm-pack test --headless --chrome
wasm-pack test --headless --firefox
wasm-pack test --headless --safari

Or you can combine multiple together:

wasm-pack test --headless --chrome --firefox --safari

Note that the --headless is in addition to the other options. Wasm-pack has always worked that way, nothing has changed recently.

As for this template specifically, you can use npm test -- --chrome (and similarly for the other browsers).

It was setup that way because different people will have different browsers, so that lets you choose which browsers to run the tests in.

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.

5 participants