swift/skip-reasons
Checks that skip calls and disabled traits name a nonempty reason, and unavailable tests carry an explanation.
Part of the swift configuration, at the recommended level. It runs at the commit stage, per file. gspot runs this check itself.
A skipped test with no reason stays off, because nobody can tell when to restore it.
What to do
Section titled “What to do”Write why the test stays off and what turns it on again, or delete it.
Example
Section titled “Example”throw XCTSkip() in a Swift test reports a missing reason. Restore the test, or give a reason such as throw XCTSkip("Requires the hardware test device").
Turn it off
Section titled “Turn it off”Turn it off for some files, with a reason:
gspot ignore swift/skip-reasons --paths "<glob>" --reason "<why>"