1
0
mirror of https://github.com/fluencelabs/wasm-bindgen synced 2025-04-17 02:42:13 +00:00

Fix tests by pinning versions of webpack ()

Looks like a newer version of webpack has broken tests, so let's use
package-lock.json to pin to an older version while we wait for a fix.
This commit is contained in:
Alex Crichton 2018-06-01 13:42:59 -05:00 committed by GitHub
parent a4428f01b6
commit ad89d8457e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 7539 additions and 9 deletions

@ -19,7 +19,7 @@ build: false
test_script: test_script:
- rustup target add wasm32-unknown-unknown - rustup target add wasm32-unknown-unknown
- yarn - npm install
- cargo test - cargo test
- cargo build --release -p wasm-bindgen-cli - cargo build --release -p wasm-bindgen-cli

@ -67,7 +67,7 @@ install:
- curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.8/install.sh | bash - curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.8/install.sh | bash
- source ~/.nvm/nvm.sh - source ~/.nvm/nvm.sh
- nvm install 10 - nvm install 10
- yarn - npm install
notifications: notifications:
email: email:

7527
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

@ -1,5 +1,8 @@
{ {
"license": "MIT", "license": "MIT",
"scripts": {
"run-webpack": "webpack"
},
"devDependencies": { "devDependencies": {
"@types/node": "^9.4.6", "@types/node": "^9.4.6",
"ts-loader": "^4.0.1", "ts-loader": "^4.0.1",

@ -300,10 +300,10 @@ impl Project {
// move files from the root into each test, it looks like this may be // move files from the root into each test, it looks like this may be
// needed for webpack to work well when invoked concurrently. // needed for webpack to work well when invoked concurrently.
fs::hard_link("package.json", root.join("package.json")).unwrap(); fs::hard_link("package.json", root.join("package.json")).unwrap();
if !Path::new("yarn.lock").exists() { if !Path::new("node_modules").exists() {
panic!("\n\nfailed to find `yarn.lock`, have you run `yarn` yet?\n\n"); panic!("\n\nfailed to find `node_modules`, have you run `npm install` yet?\n\n");
} }
fs::hard_link("yarn.lock", root.join("yarn.lock")).unwrap(); fs::hard_link("package-lock.json", root.join("package-lock.json")).unwrap();
let cwd = env::current_dir().unwrap(); let cwd = env::current_dir().unwrap();
symlink_dir(&cwd.join("node_modules"), &root.join("node_modules")).unwrap(); symlink_dir(&cwd.join("node_modules"), &root.join("node_modules")).unwrap();
@ -317,13 +317,13 @@ impl Project {
let mut cmd = if cfg!(windows) { let mut cmd = if cfg!(windows) {
let mut c = Command::new("cmd"); let mut c = Command::new("cmd");
c.arg("/c"); c.arg("/c");
c.arg("yarn"); c.arg("npm");
c c
} else { } else {
Command::new("yarn") Command::new("npm")
}; };
cmd.arg("webpack").current_dir(&root); cmd.arg("run").arg("run-webpack").current_dir(&root);
run(&mut cmd, "yarn"); run(&mut cmd, "npm");
let mut cmd = Command::new("node"); let mut cmd = Command::new("node");
cmd.args(&self.node_args); cmd.args(&self.node_args);