diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 41cf159e0c80..2bfc58be28d7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -86,22 +86,8 @@ jobs: - name: Test run: bash ./ci.sh - fmt: - name: formatting (ignored by bors) - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - name: Install latest nightly - run: | - rustup toolchain install nightly --component rustfmt - rustup override set nightly - - name: Formatting (miri, ui_test) - run: cargo fmt --all --check - - name: Formatting (cargo-miri) - run: cargo fmt --manifest-path cargo-miri/Cargo.toml --all --check - clippy: - name: clippy (ignored by bors) + name: clippy runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 @@ -117,6 +103,20 @@ jobs: - name: Clippy (cargo-miri) run: cargo clippy --manifest-path cargo-miri/Cargo.toml --all-targets -- -D warnings + fmt: + name: formatting (ignored by bors) + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Install latest nightly + run: | + rustup toolchain install nightly --component rustfmt + rustup override set nightly + - name: Formatting (miri, ui_test) + run: cargo fmt --all --check + - name: Formatting (cargo-miri) + run: cargo fmt --manifest-path cargo-miri/Cargo.toml --all --check + # These jobs doesn't actually test anything, but they're only used to tell # bors the build completed, as there is no practical way to detect when a # workflow is successful listening to webhooks only. @@ -126,7 +126,7 @@ jobs: end-success: name: bors build finished runs-on: ubuntu-latest - needs: [build] + needs: [build, clippy] if: github.event.pusher.name == 'bors' && success() steps: - name: mark the job as a success @@ -134,7 +134,7 @@ jobs: end-failure: name: bors build finished runs-on: ubuntu-latest - needs: [build] + needs: [build, clippy] if: github.event.pusher.name == 'bors' && (failure() || cancelled()) steps: - name: mark the job as a failure @@ -144,7 +144,7 @@ jobs: cron-fail-notify: name: cronjob failure notification runs-on: ubuntu-latest - needs: [build] + needs: [build, clippy] if: github.event_name == 'schedule' && (failure() || cancelled()) steps: - name: Install zulip-send diff --git a/src/lib.rs b/src/lib.rs index 982d3873d573..7d8eb92ac58e 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -16,7 +16,8 @@ clippy::new_without_default, clippy::single_match, clippy::useless_format, - clippy::derive_partial_eq_without_eq + clippy::derive_partial_eq_without_eq, + clippy::too_many_arguments )] extern crate rustc_apfloat; diff --git a/tests/pass/concurrency/linux-futex.rs b/tests/pass/concurrency/linux-futex.rs index 8a67e0b525a9..b2791a428566 100644 --- a/tests/pass/concurrency/linux-futex.rs +++ b/tests/pass/concurrency/linux-futex.rs @@ -132,7 +132,7 @@ fn wait_wake() { static FUTEX: i32 = 0; - thread::spawn(move || { + let t = thread::spawn(move || { thread::sleep(Duration::from_millis(200)); unsafe { assert_eq!(libc::syscall( @@ -155,6 +155,7 @@ fn wait_wake() { } assert!((200..1000).contains(&start.elapsed().as_millis())); + t.join().unwrap(); } fn wait_wake_bitset() { @@ -162,7 +163,7 @@ fn wait_wake_bitset() { static FUTEX: i32 = 0; - thread::spawn(move || { + let t = thread::spawn(move || { thread::sleep(Duration::from_millis(200)); unsafe { assert_eq!(libc::syscall( @@ -202,6 +203,7 @@ fn wait_wake_bitset() { } assert!((400..1000).contains(&start.elapsed().as_millis())); + t.join().unwrap(); } fn main() {