Take2 #2
This run and associated checks have been archived and are scheduled for deletion.
Learn more about checks retention
mt-annotations.yaml
on: pull_request
Matrix: tests
Annotations Status
0s
Annotations
4 warnings
Mutation Testing Code Review Annotations 8.1:
src/Command/RunCommand.php#L416
Escaped Mutant for Mutator "UnwrapTrim":
--- Original
+++ New
@@ @@
$testFramework = trim((string) $input->getOption(self::OPTION_TEST_FRAMEWORK));
$testFrameworkExtraOptions = trim((string) $input->getOption(self::OPTION_TEST_FRAMEWORK_OPTIONS));
$initialTestsPhpOptions = trim((string) $input->getOption(self::OPTION_INITIAL_TESTS_PHP_OPTIONS));
- $gitlabFileLogPath = trim((string) $input->getOption(self::OPTION_LOGGER_GITLAB));
+ $gitlabFileLogPath = (string) $input->getOption(self::OPTION_LOGGER_GITLAB);
$htmlFileLogPath = trim((string) $input->getOption(self::OPTION_LOGGER_HTML));
/** @var string|null $minMsi */
$minMsi = $input->getOption(self::OPTION_MIN_MSI);
|
Mutation Testing Code Review Annotations 8.1:
src/Command/RunCommand.php#L502
Escaped Mutant for Mutator "Identical":
--- Original
+++ New
@@ @@
$isForGitDiffLines,
$gitDiffBase,
$this->getUseGitHubLogger($input),
- $gitlabFileLogPath === '' ? Container::DEFAULT_GITLAB_LOGGER_PATH : $gitlabFileLogPath,
+ $gitlabFileLogPath !== '' ? Container::DEFAULT_GITLAB_LOGGER_PATH : $gitlabFileLogPath,
$htmlFileLogPath === '' ? Container::DEFAULT_HTML_LOGGER_PATH : $htmlFileLogPath,
(bool) $input->getOption(self::OPTION_USE_NOOP_MUTATORS),
(bool) $input->getOption(self::OPTION_EXECUTE_ONLY_COVERING_TEST_CASES)
|
Mutation Testing Code Review Annotations 8.1:
src/Command/RunCommand.php#L502
Escaped Mutant for Mutator "Ternary":
--- Original
+++ New
@@ @@
$isForGitDiffLines,
$gitDiffBase,
$this->getUseGitHubLogger($input),
- $gitlabFileLogPath === '' ? Container::DEFAULT_GITLAB_LOGGER_PATH : $gitlabFileLogPath,
+ $gitlabFileLogPath === '' ? $gitlabFileLogPath : Container::DEFAULT_GITLAB_LOGGER_PATH,
$htmlFileLogPath === '' ? Container::DEFAULT_HTML_LOGGER_PATH : $htmlFileLogPath,
(bool) $input->getOption(self::OPTION_USE_NOOP_MUTATORS),
(bool) $input->getOption(self::OPTION_EXECUTE_ONLY_COVERING_TEST_CASES)
|
Mutation Testing Code Review Annotations 8.1:
src/Logger/GitLabCodeQualityLogger.php#L58
Escaped Mutant for Mutator "UnwrapTrim":
--- Original
+++ New
@@ @@
public function getLogLines() : array
{
$lines = [];
- $projectRootDirectory = trim(shell_exec('git rev-parse --show-toplevel'));
+ $projectRootDirectory = shell_exec('git rev-parse --show-toplevel');
foreach ($this->resultsCollector->getEscapedExecutionResults() as $escapedExecutionResult) {
$lines[] = ['type' => 'issue', 'fingerprint' => $escapedExecutionResult->getMutantHash(), 'check_name' => $escapedExecutionResult->getMutatorName(), 'description' => 'Escaped Mutant for Mutator ' . $escapedExecutionResult->getMutatorName(), 'content' => Str::convertToUtf8(Str::trimLineReturns($escapedExecutionResult->getMutantDiff())), 'categories' => ['Escaped Mutant'], 'location' => ['path' => Path::makeRelative($escapedExecutionResult->getOriginalFilePath(), $projectRootDirectory), 'lines' => ['begin' => $escapedExecutionResult->getOriginalStartingLine()]], 'severity' => 'major'];
}
|