improve things

This commit is contained in:
nora 2022-02-10 05:59:35 +01:00
parent f437754618
commit a7dba08990
9 changed files with 185 additions and 26 deletions

20
xtask/src/test_js.rs Normal file
View file

@ -0,0 +1,20 @@
use crate::project_root;
use anyhow::{bail, Result};
use std::process::Command;
pub fn main() -> Result<()> {
let test_js_root = project_root().join("tests-js");
let status = Command::new("yarn").current_dir(&test_js_root).status()?;
if !status.success() {
bail!("yarn install failed");
}
let status = Command::new("yarn")
.arg("test")
.current_dir(&test_js_root)
.status()?;
if !status.success() {
bail!("yarn tests failed");
}
Ok(())
}