Skip to content

Commit

Permalink
chore(deps): update dependency rust to v1.80.0 (#40)
Browse files Browse the repository at this point in the history
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [rust](https://togithub.com/rust-lang/rust) | minor | `1.79.0` ->
`1.80.0` |

---

### Release Notes

<details>
<summary>rust-lang/rust (rust)</summary>

###
[`v1.80.0`](https://togithub.com/rust-lang/rust/compare/1.79.0...1.80.0)

[Compare
Source](https://togithub.com/rust-lang/rust/compare/1.79.0...1.80.0)

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View the
[repository job
log](https://developer.mend.io/github/Boshen/criterion2.rs).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy40MzguMCIsInVwZGF0ZWRJblZlciI6IjM3LjQzOC4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Boshen <[email protected]>
  • Loading branch information
renovate[bot] and Boshen authored Jul 25, 2024
1 parent 8dac750 commit 20ad47e
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 55 deletions.
2 changes: 1 addition & 1 deletion rust-toolchain.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[toolchain]
channel = "1.79.0"
channel = "1.80.0"
profile = "default"
54 changes: 0 additions & 54 deletions tests/criterion_tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ use std::{
time::{Duration, SystemTime},
};

#[cfg(feature = "plotters")]
use criterion::SamplingMode;
use criterion::{
criterion_group, criterion_main, profiler::Profiler, BatchSize, BenchmarkFilter, BenchmarkId,
Criterion,
Expand Down Expand Up @@ -295,58 +293,6 @@ fn test_timing_loops() {
});
}

// Verify that all expected output files are present
#[cfg(feature = "plotters")]
#[test]
fn test_output_files() {
let tempdir = temp_dir();
// Run benchmarks twice to produce comparisons
for _ in 0..2 {
let mut c = short_benchmark(&tempdir);
let mut group = c.benchmark_group("test_output");
group.sampling_mode(SamplingMode::Linear);
group.bench_function("output_1", |b| b.iter(|| 10));
group.bench_function("output_2", |b| b.iter(|| 20));
group.bench_function("output_\\/*\"?", |b| b.iter(|| 30));
}

// For each benchmark, assert that the expected files are present.
for x in 0..3 {
let dir = if x == 2 {
// Check that certain special characters are replaced with underscores
tempdir.path().join("test_output/output______")
} else {
tempdir.path().join(format!("test_output/output_{}", x + 1))
};

verify_stats(&dir, "new");
verify_stats(&dir, "base");
verify_json(&dir, "change/estimates.json");
}

// Run the final summary process and check for the report that produces
short_benchmark(&tempdir).final_summary();
}

#[cfg(feature = "plotters")]
#[test]
fn test_output_files_flat_sampling() {
let tempdir = temp_dir();
// Run benchmark twice to produce comparisons
for _ in 0..2 {
let mut c = short_benchmark(&tempdir);
let mut group = c.benchmark_group("test_output");
group.sampling_mode(SamplingMode::Flat);
group.bench_function("output_flat", |b| b.iter(|| 10));
}

let dir = tempdir.path().join("test_output/output_flat");

verify_stats(&dir, "new");
verify_stats(&dir, "base");
verify_json(&dir, "change/estimates.json");
}

#[test]
#[should_panic(expected = "Benchmark function must call Bencher::iter or related method.")]
fn test_bench_with_no_iteration_panics() {
Expand Down

0 comments on commit 20ad47e

Please sign in to comment.