diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9e8a9ca..8ae4522 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -63,9 +63,9 @@ jobs: with: toolchain: ${{matrix.rust}} components: rust-src - - run: cargo check - - run: cargo check --no-default-features - - run: cargo check --features backtrace + - run: cargo check --manifest-path tests/crate/Cargo.toml + - run: cargo check --manifest-path tests/crate/Cargo.toml --no-default-features + - run: cargo check --manifest-path tests/crate/Cargo.toml --features backtrace if: matrix.rust != '1.65.0' && matrix.rust != '1.52.0' && matrix.rust != '1.51.0' && matrix.rust != '1.50.0' && matrix.rust != '1.39.0' minimal: diff --git a/Cargo.toml b/Cargo.toml index 644181c..97eed33 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -26,7 +26,7 @@ backtrace = { version = "0.3.51", optional = true } futures = { version = "0.3", default-features = false } rustversion = "1.0.6" syn = { version = "2.0", features = ["full"] } -thiserror = "1.0.45" +thiserror = "2" trybuild = { version = "1.0.66", features = ["diff"] } [lib] diff --git a/tests/crate/Cargo.toml b/tests/crate/Cargo.toml new file mode 100644 index 0000000..d927c00 --- /dev/null +++ b/tests/crate/Cargo.toml @@ -0,0 +1,17 @@ +[package] +name = "anyhow_test" +version = "0.0.0" +authors = ["David Tolnay "] +edition = "2018" +publish = false + +[lib] +path = "test.rs" + +[dependencies] +anyhow = { path = "../..", default-features = false } + +[features] +default = ["std"] +std = ["anyhow/std"] +backtrace = ["anyhow/backtrace"] diff --git a/tests/crate/test.rs b/tests/crate/test.rs new file mode 100644 index 0000000..b978631 --- /dev/null +++ b/tests/crate/test.rs @@ -0,0 +1,3 @@ +#![no_std] + +pub use anyhow::*;