Skip to content

Commit

Permalink
fix: fix bench
Browse files Browse the repository at this point in the history
  • Loading branch information
vicanso committed Sep 2, 2023
1 parent e4b254b commit f479197
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions benches/bench.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use charts_rs::{
format_float, measure_text_width_family, svg_to_png, BarChart, Box, LegendCategory,
SeriesCategory, DEFAULT_FONT_FAMILY,
measure_text_width_family, svg_to_png, BarChart, Box, LegendCategory, SeriesCategory,
DEFAULT_FONT_FAMILY,
};
use criterion::{criterion_group, criterion_main, Criterion};

Expand Down Expand Up @@ -119,13 +119,8 @@ fn bar_chart_png_benchmark(c: &mut Criterion) {
});
}

fn format_float_benchmark(c: &mut Criterion) {
c.bench_function("format float", |b| b.iter(|| format_float(12381731.124)));
}

criterion_group!(
benches,
format_float_benchmark,
measure_text_benchmark,
bar_chart_benchmark,
bar_chart_png_benchmark,
Expand Down

0 comments on commit f479197

Please sign in to comment.