From 8b366849481f76ae7a1c738c24bf48e95aed83c6 Mon Sep 17 00:00:00 2001 From: David Tolnay Date: Wed, 24 May 2023 08:14:53 -0700 Subject: [PATCH] Hide dev-dependencies from old cargo error: failed to select a version for the requirement `clap = "^4"` candidate versions found which didn't match: 3.2.25, 3.2.24, 3.2.23, ... location searched: crates.io index required by package `criterion v0.5.0` ... which is depended on by `unicode-ident v1.0.8 (/home/runner/work/unicode-ident/unicode-ident)` --- .github/workflows/ci.yml | 4 ++-- tests/crate/.gitignore | 2 ++ tests/crate/Cargo.toml | 14 ++++++++++++++ tests/crate/test.rs | 3 +++ 4 files changed, 21 insertions(+), 2 deletions(-) create mode 100644 tests/crate/.gitignore create mode 100644 tests/crate/Cargo.toml create mode 100644 tests/crate/test.rs diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b74694e..50363ca 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -44,7 +44,7 @@ jobs: strategy: fail-fast: false matrix: - rust: [nightly, beta, stable] + rust: [nightly, beta, stable, 1.64.0] timeout-minutes: 45 steps: - uses: actions/checkout@v3 @@ -66,7 +66,7 @@ jobs: steps: - uses: actions/checkout@v3 - uses: dtolnay/rust-toolchain@1.31.0 - - run: cargo check + - run: cargo check --manifest-path tests/crate/Cargo.toml clippy: name: Clippy diff --git a/tests/crate/.gitignore b/tests/crate/.gitignore new file mode 100644 index 0000000..4fffb2f --- /dev/null +++ b/tests/crate/.gitignore @@ -0,0 +1,2 @@ +/target +/Cargo.lock diff --git a/tests/crate/Cargo.toml b/tests/crate/Cargo.toml new file mode 100644 index 0000000..5d71a4d --- /dev/null +++ b/tests/crate/Cargo.toml @@ -0,0 +1,14 @@ +[package] +name = "unicode-ident-test" +version = "0.0.0" +authors = ["David Tolnay "] +edition = "2018" +publish = false + +[lib] +path = "test.rs" + +[dependencies] +unicode-ident = { path = "../.." } + +[workspace] diff --git a/tests/crate/test.rs b/tests/crate/test.rs new file mode 100644 index 0000000..0881831 --- /dev/null +++ b/tests/crate/test.rs @@ -0,0 +1,3 @@ +#![no_std] + +pub use unicode_ident::*;