mirror of
https://github.com/rustwasm/wasm-bindgen.git
synced 2024-12-25 02:53:07 +03:00
Fix tests by pinning versions of webpack (#219)
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:
parent
a4428f01b6
commit
ad89d8457e
@ -19,7 +19,7 @@ build: false
|
||||
|
||||
test_script:
|
||||
- rustup target add wasm32-unknown-unknown
|
||||
- yarn
|
||||
- npm install
|
||||
- cargo test
|
||||
- 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
|
||||
- source ~/.nvm/nvm.sh
|
||||
- nvm install 10
|
||||
- yarn
|
||||
- npm install
|
||||
|
||||
notifications:
|
||||
email:
|
||||
|
7527
package-lock.json
generated
Normal file
7527
package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load Diff
@ -1,5 +1,8 @@
|
||||
{
|
||||
"license": "MIT",
|
||||
"scripts": {
|
||||
"run-webpack": "webpack"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/node": "^9.4.6",
|
||||
"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
|
||||
// needed for webpack to work well when invoked concurrently.
|
||||
fs::hard_link("package.json", root.join("package.json")).unwrap();
|
||||
if !Path::new("yarn.lock").exists() {
|
||||
panic!("\n\nfailed to find `yarn.lock`, have you run `yarn` yet?\n\n");
|
||||
if !Path::new("node_modules").exists() {
|
||||
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();
|
||||
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 c = Command::new("cmd");
|
||||
c.arg("/c");
|
||||
c.arg("yarn");
|
||||
c.arg("npm");
|
||||
c
|
||||
} else {
|
||||
Command::new("yarn")
|
||||
Command::new("npm")
|
||||
};
|
||||
cmd.arg("webpack").current_dir(&root);
|
||||
run(&mut cmd, "yarn");
|
||||
cmd.arg("run").arg("run-webpack").current_dir(&root);
|
||||
run(&mut cmd, "npm");
|
||||
|
||||
let mut cmd = Command::new("node");
|
||||
cmd.args(&self.node_args);
|
||||
|
Loading…
Reference in New Issue
Block a user