Skip to content

Commit

Permalink
Credit cargo-fuzz
Browse files Browse the repository at this point in the history
  • Loading branch information
0rvar committed Apr 25, 2017
1 parent ec8df91 commit 4d92016
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/consume.rs
Original file line number Diff line number Diff line change
Expand Up @@ -424,6 +424,7 @@ fn it_returns_error_when_there_are_no_mappings() {

#[test]
fn it_does_not_panic_when_querying_for_position_2() {
// Found with cargo-fuzz
let cache = consume(r#"{
"version": 3,
"file": "foo.js",
Expand All @@ -437,6 +438,7 @@ fn it_does_not_panic_when_querying_for_position_2() {

#[test]
fn it_does_not_panic_on_invalid_bit_shifts() {
// Found with cargo-fuzz
match consume(r#"{
"version": 3,
"file": "foo.js",
Expand All @@ -452,6 +454,7 @@ fn it_does_not_panic_on_invalid_bit_shifts() {

#[test]
fn it_does_not_panic_from_add_overflow() {
// Found with cargo-fuzz
match consume(r#"{
"version": 3,
"file": "foo.js",
Expand All @@ -463,4 +466,4 @@ fn it_does_not_panic_from_add_overflow() {
Err(s) => assert!(s == "Line number overflowed"),
_ => panic!("Invalid source map should fail to consume")
};
}
}

0 comments on commit 4d92016

Please sign in to comment.