Skip to content

Commit

Permalink
ci: fix msrv runs
Browse files Browse the repository at this point in the history
  • Loading branch information
camshaft committed Sep 9, 2023
1 parent 63ebde2 commit 874dca0
Show file tree
Hide file tree
Showing 271 changed files with 415 additions and 306 deletions.
73 changes: 22 additions & 51 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,44 +44,8 @@ jobs:
strategy:
fail-fast: false
matrix:
rust: [1.57.0, 1.64.0, stable, nightly]
rust: [1.57.0, stable, nightly]
os: [ubuntu-latest, macOS-latest]
# TODO add honggfuzz back
test: [unit-tests, unit-tests-no-1.57, build-no-default-features, libfuzzer, afl, examples-tests]
sanitizer: [NONE]
exclude:
- rust: 1.57.0
test: unit-tests-no-1.57
# honggfuzz is broken on macOS
- os: macos-latest
test: honggfuzz
include:
- rust: nightly
os: ubuntu-latest
test: libfuzzer
sanitizer: address
# - rust: nightly
# os: ubuntu-latest
# test: honggfuzz
# sanitizer: address
# TODO fix this
# - rust: nightly
# os: ubuntu-latest
# test: afl
# sanitizer: address
- rust: nightly
os: macOS-latest
test: libfuzzer
sanitizer: address
# - rust: nightly
# os: macOS-latest
# test: honggfuzz
# sanitizer: address
# TODO fix this
# - rust: nightly
# os: macOS-latest
# test: afl
# sanitizer: address

steps:
- name: Ubuntu setup
Expand All @@ -101,23 +65,30 @@ jobs:
- uses: actions/checkout@v3.5.3

# install stable for kani, cargo-bolero and test runner
- uses: actions-rs/toolchain@v1.0.7
with:
toolchain: stable
profile: minimal

- name: Install kani
run: |
cargo install --locked kani-verifier
cargo kani setup
- uses: actions-rs/toolchain@v1.0.7
id: toolchain
with:
toolchain: ${{ matrix.rust }}
profile: minimal
override: true

- uses: camshaft/rust-cache@v1
with:
key: ${{ matrix.test }}-${{ matrix.sanitizer }}

- name: ${{ matrix.test }}
run: make ${{ matrix.test }}
env:
AFL_I_DONT_CARE_ABOUT_MISSING_CRASHES: 1
AFL_SKIP_CPUFREQ: 1
SANITIZER: ${{ matrix.sanitizer }}
- name: Setup target rustc
if: matrix.rust != 'stable' && matrix.rust != 'nightly'
run: echo "TARGET_RUSTC=${{ matrix.rust }}" >> $GITHUB_ENV

- name: Run tests
run: cargo +stable run

kani:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -166,10 +137,10 @@ jobs:
run: |
cat <<EOF >> Cargo.toml
[patch.crates-io]
bolero = { path = "../../../../bolero" }
bolero-engine = { path = "../../../../bolero-engine" }
bolero-generator = { path = "../../../../bolero-generator" }
bolero-generator-derive = { path = "../../../../bolero-generator-derive" }
bolero = { path = "../../../../lib/bolero" }
bolero-engine = { path = "../../../../lib/bolero-engine" }
bolero-generator = { path = "../../../../lib/bolero-generator" }
bolero-generator-derive = { path = "../../../../lib/bolero-generator-derive" }
EOF
- uses: camshaft/rust-cache@v1
Expand Down
15 changes: 1 addition & 14 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,17 +1,4 @@
[workspace]
members = [
"bolero",
"bolero-*",
"cargo-bolero",
"tests",
]

[profile.fuzz]
inherits = "dev"
opt-level = 3
incremental = false
codegen-units = 1

[profile.release]
lto = true
codegen-units = 1
incremental = false
217 changes: 0 additions & 217 deletions Makefile

This file was deleted.

4 changes: 4 additions & 0 deletions bin/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[workspace]
members = [
"cargo-bolero",
]
8 changes: 5 additions & 3 deletions cargo-bolero/Cargo.toml → bin/cargo-bolero/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ keywords = ["testing", "quickcheck", "property", "fuzz", "fuzzing"]
license = "MIT"
edition = "2018"
readme = "README.md"
rust-version = "1.66.0"

[features]
default = ["afl", "libfuzzer", "kani"]
Expand All @@ -20,8 +21,8 @@ libfuzzer = []
[dependencies]
anyhow = "1.0"
bit-set = "0.5"
bolero-afl = { version = "0.9", path = "../bolero-afl", default-features = false, features = ["bin"], optional = true }
bolero-honggfuzz = { version = "0.9", path = "../bolero-honggfuzz", default-features = false, features = ["bin"], optional = true }
bolero-afl = { version = "0.9", path = "../../lib/bolero-afl", default-features = false, features = ["bin"], optional = true }
bolero-honggfuzz = { version = "0.9", path = "../../lib/bolero-honggfuzz", default-features = false, features = ["bin"], optional = true }
humantime = "2"
lazy_static = "1"
rustc_version = "0.4"
Expand All @@ -31,7 +32,7 @@ serde_json = "1.0"
tempfile = "3"

[dev-dependencies]
bolero = { version = "0.9", path = "../bolero" }
bolero = { version = "0.9", path = "../../lib/bolero" }

[[test]]
name = "fuzz_bytes"
Expand All @@ -42,3 +43,4 @@ harness = false
name = "fuzz_generator"
path = "tests/fuzz_generator/fuzz_target.rs"
harness = false

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
3 changes: 3 additions & 0 deletions bin/rust-toolchain
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[toolchain]
channel = "1.66.0"
components = [ "rustc", "clippy", "rustfmt" ]
2 changes: 1 addition & 1 deletion examples/basic/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ edition = "2018"
arrayvec = "0.5"

[dev-dependencies]
bolero = { path = "../../bolero" }
bolero = { path = "../../lib/bolero" }

[workspace]
members = ["."]
Expand Down
Loading

0 comments on commit 874dca0

Please sign in to comment.