Made the CI also check the benchmarks, fixed compile issue in benchmarks (#449)

This commit is contained in:
Trangar 2021-12-11 16:09:23 +01:00 committed by GitHub
parent 0ee07c3212
commit a5255465bd
2 changed files with 11 additions and 2 deletions

View File

@ -4,7 +4,8 @@
"push": {
"branches": [
"trunk",
"v*.x"
"v*.x",
"ci/*"
]
},
"pull_request": {
@ -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": {

View File

@ -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());
})
});