Skip to content

Commit

Permalink
Add test for non-default stroke color option
Browse files Browse the repository at this point in the history
  • Loading branch information
Urgau committed Jul 18, 2022
1 parent 1a0c72d commit 29a9d8a
Show file tree
Hide file tree
Showing 2 changed files with 152 additions and 0 deletions.
140 changes: 140 additions & 0 deletions tests/data/flamegraph/options/stroke_color.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 12 additions & 0 deletions tests/flamegraph.rs
Original file line number Diff line number Diff line change
Expand Up @@ -710,6 +710,18 @@ fn search_color_non_default() {
test_flamegraph(input_file, expected_result_file, options).unwrap();
}

#[test]
fn stroke_color_non_default() {
let input_file =
"./tests/data/flamegraph/differential/perf-cycles-instructions-01-collapsed-all-diff.txt";
let expected_result_file = "./tests/data/flamegraph/options/stroke_color.svg";

let mut options = flamegraph::Options::default();
options.stroke_color = "#7d7d7d".parse().unwrap();

test_flamegraph(input_file, expected_result_file, options).unwrap();
}

#[test]
fn flamegraph_sorted_input_file() {
let input_file = "./flamegraph/test/results/perf-vertx-stacks-01-collapsed-all.txt";
Expand Down

0 comments on commit 29a9d8a

Please sign in to comment.