From 777cd3f80aeb65a480f2bbe1b40fb8affbe6349f Mon Sep 17 00:00:00 2001 From: konsumlamm Date: Mon, 19 Jul 2021 19:20:53 +0200 Subject: [PATCH] Move test_suite to tests --- .github/workflows/rust.yml | 25 ------------------- Cargo.toml | 18 ++++++------- test_suite/Cargo.toml | 11 -------- .../compile-fail/private_flags.rs | 0 {test_suite/tests => tests}/compiletest.rs | 0 .../conflicting_trait_impls.rs | 0 {test_suite/tests => tests}/external.rs | 0 .../tests => tests}/external_no_std.rs | 0 {test_suite/tests => tests}/redefine_core.rs | 0 {test_suite/tests => tests}/serde.rs | 0 {test_suite/tests => tests}/u128_bitflags.rs | 2 -- 11 files changed, 9 insertions(+), 47 deletions(-) delete mode 100644 test_suite/Cargo.toml rename {test_suite/tests => tests}/compile-fail/private_flags.rs (100%) rename {test_suite/tests => tests}/compiletest.rs (100%) rename {test_suite/tests => tests}/conflicting_trait_impls.rs (100%) rename {test_suite/tests => tests}/external.rs (100%) rename {test_suite/tests => tests}/external_no_std.rs (100%) rename {test_suite/tests => tests}/redefine_core.rs (100%) rename {test_suite/tests => tests}/serde.rs (100%) rename {test_suite/tests => tests}/u128_bitflags.rs (96%) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 2bb37c1..ffe0eda 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -54,28 +54,3 @@ jobs: with: command: build args: -Z avoid-dev-deps --features example_generated --target thumbv6m-none-eabi - - suite: - name: Test suite - runs-on: ubuntu-latest - strategy: - fail-fast: true - matrix: - rust: - - nightly - steps: - - name: Checkout sources - uses: actions/checkout@v2 - - - name: Install Rust toolchain - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: ${{ matrix.rust }} - override: true - - - name: Default features - uses: actions-rs/cargo@v1 - with: - command: test - args: -p test_suite \ No newline at end of file diff --git a/Cargo.toml b/Cargo.toml index c6e8c9e..44d0f19 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,10 +1,10 @@ [package] - name = "bitflags" # NB: When modifying, also modify: # 1. html_root_url in lib.rs # 2. number in readme (for breaking changes) version = "1.2.1" +edition = "2018" authors = ["The Rust Project Developers"] license = "MIT/Apache-2.0" keywords = ["bit", "bitmask", "bitflags", "flags"] @@ -16,22 +16,22 @@ categories = ["no-std"] description = """ A macro to generate structures which behave like bitflags. """ -exclude = [ - "appveyor.yml", - "bors.toml" -] +exclude = ["bors.toml"] [dependencies] core = { version = '1.0.0', optional = true, package = 'rustc-std-workspace-core' } compiler_builtins = { version = '0.1.2', optional = true } +[dev-dependencies] +trybuild = "1.0" +serde = "1.0" +serde_derive = "1.0" +serde_json = "1.0" + [features] default = [] example_generated = [] rustc-dep-of-std = ["core", "compiler_builtins"] [package.metadata.docs.rs] -features = [ "example_generated" ] - -[workspace] -members = ["test_suite"] +features = ["example_generated"] diff --git a/test_suite/Cargo.toml b/test_suite/Cargo.toml deleted file mode 100644 index ac459d5..0000000 --- a/test_suite/Cargo.toml +++ /dev/null @@ -1,11 +0,0 @@ -[project] -name = "test_suite" -version = "0.0.0" -edition = "2018" - -[dependencies] -bitflags = { path = "../" } -trybuild = "1.0" -serde = "1.0" -serde_derive = "1.0" -serde_json = "1.0" diff --git a/test_suite/tests/compile-fail/private_flags.rs b/tests/compile-fail/private_flags.rs similarity index 100% rename from test_suite/tests/compile-fail/private_flags.rs rename to tests/compile-fail/private_flags.rs diff --git a/test_suite/tests/compiletest.rs b/tests/compiletest.rs similarity index 100% rename from test_suite/tests/compiletest.rs rename to tests/compiletest.rs diff --git a/test_suite/tests/conflicting_trait_impls.rs b/tests/conflicting_trait_impls.rs similarity index 100% rename from test_suite/tests/conflicting_trait_impls.rs rename to tests/conflicting_trait_impls.rs diff --git a/test_suite/tests/external.rs b/tests/external.rs similarity index 100% rename from test_suite/tests/external.rs rename to tests/external.rs diff --git a/test_suite/tests/external_no_std.rs b/tests/external_no_std.rs similarity index 100% rename from test_suite/tests/external_no_std.rs rename to tests/external_no_std.rs diff --git a/test_suite/tests/redefine_core.rs b/tests/redefine_core.rs similarity index 100% rename from test_suite/tests/redefine_core.rs rename to tests/redefine_core.rs diff --git a/test_suite/tests/serde.rs b/tests/serde.rs similarity index 100% rename from test_suite/tests/serde.rs rename to tests/serde.rs diff --git a/test_suite/tests/u128_bitflags.rs b/tests/u128_bitflags.rs similarity index 96% rename from test_suite/tests/u128_bitflags.rs rename to tests/u128_bitflags.rs index 8ed1546..7501db7 100644 --- a/test_suite/tests/u128_bitflags.rs +++ b/tests/u128_bitflags.rs @@ -1,5 +1,3 @@ -#![cfg(feature = "unstable")] - use bitflags::bitflags; bitflags! {