Skip to content

Commit

Permalink
Update tests: no dupes!
Browse files Browse the repository at this point in the history
  • Loading branch information
sourcefrog committed Dec 15, 2023
1 parent 948f823 commit e047f3e
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 99 deletions.
2 changes: 1 addition & 1 deletion src/visit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ impl<'o> DiscoveryVisitor<'o> {
// The original block has braces and the replacements don't, so put
// them back for the comparison...
let new_block = quote!( { #rep } ).to_token_stream().to_pretty_string();
dbg!(&orig_block, &new_block);
// dbg!(&orig_block, &new_block);
if orig_block == new_block {
debug!("Replacement is the same as the function body; skipping");
} else {
Expand Down
90 changes: 0 additions & 90 deletions tests/cli/snapshots/cli__list_mutants_in_all_trees_as_json.snap
Original file line number Diff line number Diff line change
Expand Up @@ -2440,36 +2440,6 @@ expression: buf
}
}
},
{
"file": "src/a.rs",
"function": {
"function_name": "one",
"return_type": "-> i32",
"span": {
"end": {
"column": 2,
"line": 3
},
"start": {
"column": 1,
"line": 1
}
}
},
"genre": "FnValue",
"package": "cargo-mutants-testdata-unapply",
"replacement": "1",
"span": {
"end": {
"column": 6,
"line": 2
},
"start": {
"column": 5,
"line": 2
}
}
},
{
"file": "src/a.rs",
"function": {
Expand Down Expand Up @@ -2530,36 +2500,6 @@ expression: buf
}
}
},
{
"file": "src/b.rs",
"function": {
"function_name": "one_untested",
"return_type": "-> i32",
"span": {
"end": {
"column": 2,
"line": 3
},
"start": {
"column": 1,
"line": 1
}
}
},
"genre": "FnValue",
"package": "cargo-mutants-testdata-unapply",
"replacement": "1",
"span": {
"end": {
"column": 6,
"line": 2
},
"start": {
"column": 5,
"line": 2
}
}
},
{
"file": "src/b.rs",
"function": {
Expand Down Expand Up @@ -2620,36 +2560,6 @@ expression: buf
}
}
},
{
"file": "src/c.rs",
"function": {
"function_name": "one",
"return_type": "-> i32",
"span": {
"end": {
"column": 2,
"line": 3
},
"start": {
"column": 1,
"line": 1
}
}
},
"genre": "FnValue",
"package": "cargo-mutants-testdata-unapply",
"replacement": "1",
"span": {
"end": {
"column": 6,
"line": 2
},
"start": {
"column": 5,
"line": 2
}
}
},
{
"file": "src/c.rs",
"function": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -234,13 +234,10 @@ src/lib.rs:6:5: replace try_value_coercion -> String with "xyzzy".into()
```
src/a.rs:2:5: replace one -> i32 with 0
src/a.rs:2:5: replace one -> i32 with 1
src/a.rs:2:5: replace one -> i32 with -1
src/b.rs:2:5: replace one_untested -> i32 with 0
src/b.rs:2:5: replace one_untested -> i32 with 1
src/b.rs:2:5: replace one_untested -> i32 with -1
src/c.rs:2:5: replace one -> i32 with 0
src/c.rs:2:5: replace one -> i32 with 1
src/c.rs:2:5: replace one -> i32 with -1
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,9 @@
source: tests/cli/main.rs
expression: stdout
---
Found 9 mutants to test
Found 6 mutants to test
Unmutated baseline ... ok
src/a.rs:2:5: replace one -> i32 with 1 ... NOT CAUGHT
src/b.rs:2:5: replace one_untested -> i32 with 0 ... NOT CAUGHT
src/b.rs:2:5: replace one_untested -> i32 with 1 ... NOT CAUGHT
src/b.rs:2:5: replace one_untested -> i32 with -1 ... NOT CAUGHT
src/c.rs:2:5: replace one -> i32 with 1 ... NOT CAUGHT
9 mutants tested: 5 missed, 4 caught
6 mutants tested: 2 missed, 4 caught

0 comments on commit e047f3e

Please sign in to comment.