Skip to content

Commit

Permalink
shouldi: tests: Update versions of rust and cargo-audit
Browse files Browse the repository at this point in the history
Signed-off-by: John Andersen <johnandersenpdx@gmail.com>
  • Loading branch information
pdxjohnny committed May 10, 2021
1 parent a385f7d commit acd139b
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 12 deletions.
8 changes: 4 additions & 4 deletions examples/shouldi/tests/binaries.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,16 +58,16 @@

# Rust
CACHED_RUST = (
"https://static.rust-lang.org/dist/rust-1.50.0-x86_64-unknown-linux-gnu.tar.gz",
"https://static.rust-lang.org/dist/rust-1.52.0-x86_64-unknown-linux-gnu.tar.gz",
downloads / "rust.tar.gz",
downloads / "rust-download",
"f6eb40e09d7fa6f38f7374f6736a773b01ac191e5d421d583b7e7dd4d07c44fc6b8a7a2637af780cfab08b91715f8147",
"816355b36682fdd888da4dca19b9b08c9670d49d7f4bf4ecfd9fafad8e966ebbf7b393f3e3b07705355cb420698daf4e",
)
CACHED_CARGO_AUDIT = (
"https://github.com/RustSec/cargo-audit/archive/v0.14.0.tar.gz",
"https://github.com/RustSec/cargo-audit/archive/v0.14.1.tar.gz",
downloads / "cargo_audit.tar.gz",
downloads / "cargo-audit-download",
"871b353a43c1c90892c85534c688a4a74c8b488ae2f7851e6e0753810f4423a4176d24eb707dd8e4ba31afd7785f1205",
"594bd8f82473ca61c40a915eecb896c6f8608437bb91ae41d531d851285a584e2d7d1c37845f897c71d80260df051950",
)
CACHED_TARGET_RUST_CLIPPY = (
"https://github.com/rust-lang/rust-clippy/archive/52c25e9136f533c350fa1916b5bf5103f69c0f4d.tar.gz",
Expand Down
8 changes: 4 additions & 4 deletions examples/shouldi/tests/test_cargo_audit.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,18 +24,18 @@ async def test_run(self):
*CACHED_TARGET_RUST_CLIPPY
)
if not (
cargo_audit / "rustsec-0.14.0" / "target" / "release" / "rustsec"
cargo_audit / "rustsec-0.14.1" / "target" / "release" / "rustsec"
).is_file():
await run_cargo_build(cargo_audit / "rustsec-0.14.0")
await run_cargo_build(cargo_audit / "rustsec-0.14.1")

# Fix for https://github.com/RustSec/rustsec/issues/331
advisory_db_path = pathlib.Path("~", ".cargo", "advisory-db")
if advisory_db_path.is_dir():
shutil.rmtree(str(advisory_db_path))

with prepend_to_path(
rust / "rust-1.50.0-x86_64-unknown-linux-gnu" / "cargo" / "bin",
cargo_audit / "rustsec-0.14.0" / "target" / "release",
rust / "rust-1.52.0-x86_64-unknown-linux-gnu" / "cargo" / "bin",
cargo_audit / "rustsec-0.14.1" / "target" / "release",
):
results = await run_cargo_audit(
str(
Expand Down
8 changes: 4 additions & 4 deletions examples/shouldi/tests/test_cli_use.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,24 +75,24 @@ async def test_use_rust(self):
[
str(
rust
/ "rust-1.50.0-x86_64-unknown-linux-gnu"
/ "rust-1.52.0-x86_64-unknown-linux-gnu"
/ "install.sh"
),
f"--prefix={(rust / 'rust-install').resolve()}",
]
)
with prepend_to_path(
rust / "rust-install" / "bin",
cargo_audit / "rustsec-0.14.0" / "target" / "release",
cargo_audit / "rustsec-0.14.1" / "target" / "release",
):
if not (
cargo_audit
/ "rustsec-0.14.0"
/ "rustsec-0.14.1"
/ "target"
/ "release"
/ "cargo-audit"
).is_file():
await run_cargo_build(cargo_audit / "rustsec-0.14.0")
await run_cargo_build(cargo_audit / "rustsec-0.14.1")

# Fix for https://github.com/RustSec/cargo-audit/issues/331
advisory_db_path = pathlib.Path("~", ".cargo", "advisory-db")
Expand Down

0 comments on commit acd139b

Please sign in to comment.