Skip to content

Commit

Permalink
Made the CI also check the benchmarks, fixed compile issue in benchma…
Browse files Browse the repository at this point in the history
…rks (#449)
  • Loading branch information
VictorKoenders authored Dec 11, 2021
1 parent fffe5d9 commit 1b1e053
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
11 changes: 10 additions & 1 deletion .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
"push": {
"branches": [
"trunk",
"v*.x"
"v*.x",
"ci/*"
]
},
"pull_request": {
Expand Down Expand Up @@ -51,6 +52,14 @@
},
"name": "Run `cargo check`"
},
{
"uses": "actions-rs/cargo@v1",
"with": {
"command": "check",
"args": "--bench *"
},
"name": "Run `cargo check` on benches"
},
{
"uses": "actions-rs/cargo@v1",
"with": {
Expand Down
2 changes: 1 addition & 1 deletion benches/inline.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ fn inline_decoder_claim_bytes_read(c: &mut Criterion) {

c.bench_function("inline_decoder_claim_bytes_read", |b| {
b.iter(|| {
let _: Vec<String> =
let _: (Vec<String>, usize) =
black_box(bincode::decode_from_slice(black_box(&slice), config).unwrap());
})
});
Expand Down

0 comments on commit 1b1e053

Please sign in to comment.