Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 0 additions & 10 deletions .cargo/mutants.toml
Original file line number Diff line number Diff line change
@@ -1,17 +1,7 @@
# The same runner as the `elo-test` gate.
test_tool = "nextest"

# Above the limit on one test in `.config/nextest.toml`, with room for a test that starts just before
# another test fails. So nextest ends each run first.
minimum_test_timeout = 80

# Do not copy what git ignores to a build directory. Without this, each one gets all of
# `fuzz/target`. This also drops the committed seeds. Only `cfg(fuzzing)` code reads them, and a
# run does not build that code.
gitignore = true

# The text of an error is for a person. A test of that text only repeats the literal, so this class
# needs no test. L3 reads the text of `RunError`. That test still runs, but this mutant does not.
#
# cargo-mutants does not apply this list to a `delete field` mutant, so that mutant needs a test.
exclude_re = ['<impl std::fmt::Display for \w*Error>::fmt']
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
id: no-bash-comments
snapshots:
"# a\necho":
labels:
- source: "# a"
style: primary
start: 0
end: 3
"#!/usr/bin/env bash":
labels:
- source: "#!/usr/bin/env bash"
style: primary
start: 0
end: 19
"''\n #! a\n''":
labels:
- source: "#! a"
style: primary
start: 5
end: 9
"''\n echo\n #!/bin/sh\n''":
labels:
- source: "#!/bin/sh"
style: primary
start: 12
end: 21
"echo a # b":
labels:
- source: "# b"
style: primary
start: 7
end: 10
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
id: no-nix-comments
snapshots:
"# a\n1":
labels:
- source: "# a"
style: primary
start: 0
end: 3
/* a */ 1:
labels:
- source: /* a */
style: primary
start: 0
end: 7
"1 # a":
labels:
- source: "# a"
style: primary
start: 2
end: 5
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
id: no-nix-string-comments
snapshots:
"''\n # a\n echo\n''":
labels:
- source: |2

# a
echo
style: primary
start: 2
end: 16
- source: |-
''
# a
echo
''
style: secondary
start: 0
end: 18
"''\n echo\n #! a\n''":
labels:
- source: |2

echo
#! a
style: primary
start: 2
end: 17
- source: |-
''
echo
#! a
''
style: secondary
start: 0
end: 19
"''\n echo\n #a\n''":
labels:
- source: |2

echo
#a
style: primary
start: 2
end: 15
- source: |-
''
echo
#a
''
style: secondary
start: 0
end: 17
"''\n echo ${x}\n # a\n''":
labels:
- source: |2

# a
style: primary
start: 14
end: 21
- source: |-
''
echo ${x}
# a
''
style: secondary
start: 0
end: 23
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
id: no-rust-comments
snapshots:
"/* a */\nfn f() {}":
labels:
- source: /* a */
style: primary
start: 0
end: 7
"// a\nfn f() {}":
labels:
- source: // a
style: primary
start: 0
end: 4
//! a:
labels:
- source: //! a
style: primary
start: 0
end: 5
"/// a\nfn f() {}":
labels:
- source: |
/// a
style: primary
start: 0
end: 6
"fn f() { g(/* a */) }":
labels:
- source: /* a */
style: primary
start: 11
end: 18
"fn f() {} // a":
labels:
- source: // a
style: primary
start: 10
end: 14
Original file line number Diff line number Diff line change
@@ -0,0 +1,196 @@
id: no-rust-doc-attributes
snapshots:
"#![cfg_attr(test, doc = \"a\")]":
labels:
- source: doc
style: primary
start: 18
end: 21
- source: cfg_attr
style: secondary
start: 3
end: 11
- source: (test, doc = "a")
style: secondary
start: 11
end: 28
- source: "="
style: secondary
start: 22
end: 23
"#![doc = \"a\"]":
labels:
- source: doc = "a"
style: primary
start: 3
end: 12
- source: "\"a\""
style: secondary
start: 9
end: 12
- source: doc
style: secondary
start: 3
end: 6
"#[cfg_attr(test, cfg_attr(unix, doc = \"a\"))]\nfn f() {}":
labels:
- source: doc
style: primary
start: 32
end: 35
- source: cfg_attr
style: secondary
start: 17
end: 25
- source: (unix, doc = "a")
style: secondary
start: 25
end: 42
- source: "="
style: secondary
start: 36
end: 37
"#[cfg_attr(test, derive(Debug), doc = \"a\")]\nstruct S;":
labels:
- source: doc
style: primary
start: 32
end: 35
- source: cfg_attr
style: secondary
start: 2
end: 10
- source: (test, derive(Debug), doc = "a")
style: secondary
start: 10
end: 42
- source: "="
style: secondary
start: 36
end: 37
"#[cfg_attr(test, doc = \"a\")]\nfn f() {}":
labels:
- source: doc
style: primary
start: 17
end: 20
- source: cfg_attr
style: secondary
start: 2
end: 10
- source: (test, doc = "a")
style: secondary
start: 10
end: 27
- source: "="
style: secondary
start: 21
end: 22
"#[doc = \"a\"]\nfn f() {}":
labels:
- source: doc = "a"
style: primary
start: 2
end: 11
- source: "\"a\""
style: secondary
start: 8
end: 11
- source: doc
style: secondary
start: 2
end: 5
"#[doc = concat!(\"a\", \"b\")]\nfn f() {}":
labels:
- source: doc = concat!("a", "b")
style: primary
start: 2
end: 25
- source: concat!("a", "b")
style: secondary
start: 8
end: 25
- source: doc
style: secondary
start: 2
end: 5
"#[doc = include_str!(\"a.md\")]\nfn f() {}":
labels:
- source: doc = include_str!("a.md")
style: primary
start: 2
end: 28
- source: include_str!("a.md")
style: secondary
start: 8
end: 28
- source: doc
style: secondary
start: 2
end: 5
"macro_rules! m { ($t:expr) => { #![doc = $t] }; }":
labels:
- source: doc
style: primary
start: 35
end: 38
- source: '#'
style: secondary
start: 32
end: 33
- source: "!"
style: secondary
start: 33
end: 34
- source: "[doc = $t]"
style: secondary
start: 34
end: 44
- source: "="
style: secondary
start: 39
end: 40
- source: "["
style: secondary
start: 34
end: 35
"macro_rules! m { ($t:expr) => { #[doc = $t] fn f() {} }; }":
labels:
- source: doc
style: primary
start: 34
end: 37
- source: '#'
style: secondary
start: 32
end: 33
- source: "[doc = $t]"
style: secondary
start: 33
end: 43
- source: "="
style: secondary
start: 38
end: 39
- source: "["
style: secondary
start: 33
end: 34
"macro_rules! m { () => { #[cfg_attr(test, doc = \"a\")] fn f() {} }; }":
labels:
- source: doc
style: primary
start: 42
end: 45
- source: cfg_attr
style: secondary
start: 27
end: 35
- source: (test, doc = "a")
style: secondary
start: 35
end: 52
- source: "="
style: secondary
start: 46
end: 47
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
id: no-toml-comments
snapshots:
"# a\nkey = 1":
labels:
- source: "# a"
style: primary
start: 0
end: 3
"key = 1 # a":
labels:
- source: "# a"
style: primary
start: 8
end: 11
Loading