Improve 'cargo tree' check (#1200)

The '! cargo tree -i openssl-sys' command ignores when 'cargo tree'
fails for other reasons than not depending on the openssl-sys crate.
This commit changes the command to propagate such a failure.
This commit is contained in:
Stefan Kreutz 2023-08-05 18:11:01 +02:00 committed by GitHub
parent b1b32e7717
commit d6ea7bbbc4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -118,9 +118,7 @@ jobs:
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- name: Check that rustls-tls feature doesn't depend on OpenSSL
shell: bash
run: |
! cargo tree --package lychee --no-default-features --features rustls-tls -i openssl-sys
run: test -z "$( cargo tree --package lychee --no-default-features --features rustls-tls --prefix none | sed -n '/^openssl-sys /p' )"
- name: Run cargo check with default features
uses: actions-rs/cargo@v1
with: