Skip to content

Commit 26265bb

Browse files
committed
ci: Sync clippy and clippy_bors workflows
Those workflows should always test exactly the same things
1 parent f0e6ce8 commit 26265bb

File tree

2 files changed

+17
-3
lines changed

2 files changed

+17
-3
lines changed

.github/workflows/clippy.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ env:
2727

2828
jobs:
2929
base:
30+
# NOTE: If you modify this job, make sure you copy the changes to clippy_bors.yml
3031
runs-on: ubuntu-latest
3132

3233
steps:
@@ -50,9 +51,6 @@ jobs:
5051
- name: Build
5152
run: cargo build --features deny-warnings,internal-lints
5253

53-
- name: Test "--fix -Zunstable-options"
54-
run: cargo run --features deny-warnings,internal-lints --bin cargo-clippy -- clippy --fix -Zunstable-options
55-
5654
- name: Test
5755
run: cargo test --features deny-warnings,internal-lints
5856

@@ -72,6 +70,10 @@ jobs:
7270
run: ../target/debug/cargo-clippy
7371
working-directory: clippy_workspace_tests
7472

73+
- name: Test cargo-clippy --fix
74+
run: ../target/debug/cargo-clippy clippy --fix -Zunstable-options
75+
working-directory: clippy_workspace_tests
76+
7577
- name: Test clippy-driver
7678
run: bash .github/driver.sh
7779
env:

.github/workflows/clippy_bors.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ jobs:
7272

7373
runs-on: ${{ matrix.os }}
7474

75+
# NOTE: If you modify this job, make sure you copy the changes to clippy.yml
7576
steps:
7677
# Setup
7778
- uses: rust-lang/simpleinfra/github-actions/cancel-outdated-builds@master
@@ -131,11 +132,22 @@ jobs:
131132
run: ../target/debug/cargo-clippy
132133
working-directory: clippy_workspace_tests
133134

135+
- name: Test cargo-clippy --fix
136+
run: ../target/debug/cargo-clippy clippy --fix -Zunstable-options
137+
working-directory: clippy_workspace_tests
138+
134139
- name: Test clippy-driver
135140
run: bash .github/driver.sh
136141
env:
137142
OS: ${{ runner.os }}
138143

144+
- name: Test cargo dev new lint
145+
run: |
146+
cargo dev new_lint --name new_early_pass --pass early
147+
cargo dev new_lint --name new_late_pass --pass late
148+
cargo check
149+
git reset --hard HEAD
150+
139151
integration_build:
140152
needs: changelog
141153
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)