Skip to content

Commit

Permalink
tests fix (#223)
Browse files Browse the repository at this point in the history
  • Loading branch information
macovedj authored Jan 30, 2024
1 parent 14a0aea commit b344430
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 10 deletions.
9 changes: 1 addition & 8 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -179,14 +179,7 @@ pub async fn run_cargo_command(
.unwrap_or_else(|| {
(
PathAndArgs::new("wasmtime")
.args(vec![
"-W",
"component-model",
"-S",
"preview2",
"-S",
"common",
])
.args(vec!["-S", "preview2", "-S", "common"])
.to_owned(),
true,
)
Expand Down
9 changes: 7 additions & 2 deletions tests/metadata.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ fn it_prints_metadata() -> Result<()> {
project
.cargo_component("metadata --format-version 1")
.assert()
.stdout(contains("foo 0.1.0"))
.stdout(contains(r#""name":"foo","version":"0.1.0""#))
.success();

Ok(())
Expand Down Expand Up @@ -80,7 +80,12 @@ members = ["foo", "bar", "baz"]
project
.cargo_component("metadata --format-version 1")
.assert()
.stdout(contains("foo 0.1.0").and(contains("bar 0.1.0").and(contains("baz 0.1.0"))))
.stdout(
contains(r#"name":"foo","version":"0.1.0""#).and(
contains(r#"name":"bar","version":"0.1.0""#)
.and(contains(r#"name":"baz","version":"0.1.0""#)),
),
)
.success();

Ok(())
Expand Down

0 comments on commit b344430

Please sign in to comment.