Lower msi for infection #5
ci.yml
on: push
Dependency Validation
29s
Coding Guidelines
18s
Matrix: Unit Tests
Annotations
10 warnings
|
Mutation Tests:
src/SoureCodeScreenBundle.php#L153
Escaped Mutant for Mutator "ConcatOperandRemoval":
@@ @@
$services->set(self::$PREFIX . 'command.run', ScreenRunCommand::class)->args([service(self::$PREFIX . 'provider.chain'), service('event_dispatcher'), param('kernel.project_dir'), param('kernel.environment')])->tag('console.command', ['command' => 'screen:run', 'hidden' => true]);
$services->set(self::$PREFIX . 'command.attach', ScreenAttachCommand::class)->args([service(self::$PREFIX . 'provider.chain'), service(self::$PREFIX . 'manager')])->tag('console.command', ['command' => 'screen:attach']);
$services->set(self::$PREFIX . 'command.kill', ScreenKillCommand::class)->args([service(self::$PREFIX . 'provider.chain'), service(self::$PREFIX . 'manager')])->tag('console.command', ['command' => 'screen:kill']);
- $services->set(self::$PREFIX . 'command.log', ScreenLogCommand::class)->args([service(self::$PREFIX . 'provider.chain'), service(self::$PREFIX . 'manager')])->tag('console.command', ['command' => 'screen:log']);
+ $services->set(self::$PREFIX, ScreenLogCommand::class)->args([service(self::$PREFIX . 'provider.chain'), service(self::$PREFIX . 'manager')])->tag('console.command', ['command' => 'screen:log']);
$services->set(self::$PREFIX . 'command.start', ScreenStartCommand::class)->args([service(self::$PREFIX . 'provider.chain'), service(self::$PREFIX . 'manager')])->tag('console.command', ['command' => 'screen:start']);
$services->set(self::$PREFIX . 'command.restart', ScreenStartCommand::class)->args([service(self::$PREFIX . 'provider.chain'), service(self::$PREFIX . 'manager')])->tag('console.command', ['command' => 'screen:restart']);
$services->set(self::$PREFIX . 'command.status', ScreenStatusCommand::class)->args([service(self::$PREFIX . 'provider.chain'), service(self::$PREFIX . 'manager')])->tag('console.command', ['command' => 'screen:status']);
|
|
Mutation Tests:
src/Manager/ScreenManager.php#L182
Escaped Mutant for Mutator "DecrementInteger":
@@ @@
* @param int $timeout - Time to wait in seconds for the screen to kill after trying to gracefully stop it
* @param int $sleep - Time to sleep in microseconds between checks
*/
- public function kill(ScreenInterface|string $nameOrScreen, int $timeout = 5, int $sleep = 1000): bool
+ public function kill(ScreenInterface|string $nameOrScreen, int $timeout = 4, int $sleep = 1000): bool
{
if (\is_string($nameOrScreen)) {
if (!$this->provider->has($nameOrScreen)) {
|
|
Mutation Tests:
src/Manager/ScreenManager.php#L104
Escaped Mutant for Mutator "ArrayItem":
@@ @@
$this->logger->info(\sprintf('Starting screen "%s"', $screen->getName()), ['screen' => $screen->getName(), 'command' => $screen->getCommand(), 'php' => $phpBinary, 'console' => $consoleBinary, 'environment' => $this->environment]);
$process = new Process(['screen', '-L', '-Logfile', $logFile, '-dmS', $screenName, $phpBinary, $consoleBinary, 'screen:run', $screen->getName()], $this->getBaseDirectory(), ['APP_ENV' => $this->environment], null, 5);
$process->run();
- $this->logger->info(\sprintf('Screen "%s" started', $screen->getName()), ['screen' => $screen->getName(), 'command' => $screen->getCommand(), 'php' => $phpBinary, 'console' => $consoleBinary, 'environment' => $this->environment, 'output' => $process->getOutput(), 'errorOutput' => $process->getErrorOutput(), 'exitCode' => $process->getExitCode()]);
+ $this->logger->info(\sprintf('Screen "%s" started', $screen->getName()), ['screen' => $screen->getName(), 'command' => $screen->getCommand(), 'php' => $phpBinary, 'console' => $consoleBinary, 'environment' > $this->environment, 'output' => $process->getOutput(), 'errorOutput' => $process->getErrorOutput(), 'exitCode' => $process->getExitCode()]);
return $process->isSuccessful();
}
public function stop(ScreenInterface|string $nameOrScreen): bool
|
|
Mutation Tests:
src/Manager/ScreenManager.php#L101
Escaped Mutant for Mutator "ArrayItem":
@@ @@
$this->logger->info(\sprintf('Starting screen "%s"', $screen->getName()), ['screen' => $screen->getName(), 'command' => $screen->getCommand(), 'php' => $phpBinary, 'console' => $consoleBinary, 'environment' => $this->environment]);
$process = new Process(['screen', '-L', '-Logfile', $logFile, '-dmS', $screenName, $phpBinary, $consoleBinary, 'screen:run', $screen->getName()], $this->getBaseDirectory(), ['APP_ENV' => $this->environment], null, 5);
$process->run();
- $this->logger->info(\sprintf('Screen "%s" started', $screen->getName()), ['screen' => $screen->getName(), 'command' => $screen->getCommand(), 'php' => $phpBinary, 'console' => $consoleBinary, 'environment' => $this->environment, 'output' => $process->getOutput(), 'errorOutput' => $process->getErrorOutput(), 'exitCode' => $process->getExitCode()]);
+ $this->logger->info(\sprintf('Screen "%s" started', $screen->getName()), ['screen' => $screen->getName(), 'command' > $screen->getCommand(), 'php' => $phpBinary, 'console' => $consoleBinary, 'environment' => $this->environment, 'output' => $process->getOutput(), 'errorOutput' => $process->getErrorOutput(), 'exitCode' => $process->getExitCode()]);
return $process->isSuccessful();
}
public function stop(ScreenInterface|string $nameOrScreen): bool
|
|
Mutation Tests:
src/Manager/ScreenManager.php#L100
Escaped Mutant for Mutator "ArrayItem":
@@ @@
$this->logger->info(\sprintf('Starting screen "%s"', $screen->getName()), ['screen' => $screen->getName(), 'command' => $screen->getCommand(), 'php' => $phpBinary, 'console' => $consoleBinary, 'environment' => $this->environment]);
$process = new Process(['screen', '-L', '-Logfile', $logFile, '-dmS', $screenName, $phpBinary, $consoleBinary, 'screen:run', $screen->getName()], $this->getBaseDirectory(), ['APP_ENV' => $this->environment], null, 5);
$process->run();
- $this->logger->info(\sprintf('Screen "%s" started', $screen->getName()), ['screen' => $screen->getName(), 'command' => $screen->getCommand(), 'php' => $phpBinary, 'console' => $consoleBinary, 'environment' => $this->environment, 'output' => $process->getOutput(), 'errorOutput' => $process->getErrorOutput(), 'exitCode' => $process->getExitCode()]);
+ $this->logger->info(\sprintf('Screen "%s" started', $screen->getName()), ['screen' > $screen->getName(), 'command' => $screen->getCommand(), 'php' => $phpBinary, 'console' => $consoleBinary, 'environment' => $this->environment, 'output' => $process->getOutput(), 'errorOutput' => $process->getErrorOutput(), 'exitCode' => $process->getExitCode()]);
return $process->isSuccessful();
}
public function stop(ScreenInterface|string $nameOrScreen): bool
|
|
Mutation Tests:
src/Manager/ScreenManager.php#L59
Escaped Mutant for Mutator "LogicalNot":
@@ @@
}
$screenName = $this->generateScreenName($screen);
$logDir = $this->getLogDirectory();
- if (!$this->filesystem->exists($logDir)) {
+ if ($this->filesystem->exists($logDir)) {
$this->filesystem->mkdir($logDir);
}
$logFile = $this->getLogFile($screenName);
|
|
Mutation Tests:
src/Manager/ScreenManager.php#L26
Escaped Mutant for Mutator "ConcatOperandRemoval":
@@ @@
}
public function generateScreenName(ScreenInterface $screen): string
{
- return hash('sha256', $this->getBaseDirectory() . $screen->getName() . implode('', $screen->getCommand()));
+ return hash('sha256', $this->getBaseDirectory() . $screen->getName());
}
private function getLogDirectory(): string
{
|
|
Mutation Tests:
src/Manager/ScreenManager.php#L26
Escaped Mutant for Mutator "Concat":
@@ @@
}
public function generateScreenName(ScreenInterface $screen): string
{
- return hash('sha256', $this->getBaseDirectory() . $screen->getName() . implode('', $screen->getCommand()));
+ return hash('sha256', $screen->getName() . $this->getBaseDirectory() . implode('', $screen->getCommand()));
}
private function getLogDirectory(): string
{
|
|
Mutation Tests:
src/Manager/ScreenManager.php#L26
Escaped Mutant for Mutator "ConcatOperandRemoval":
@@ @@
}
public function generateScreenName(ScreenInterface $screen): string
{
- return hash('sha256', $this->getBaseDirectory() . $screen->getName() . implode('', $screen->getCommand()));
+ return hash('sha256', $this->getBaseDirectory() . implode('', $screen->getCommand()));
}
private function getLogDirectory(): string
{
|
|
Mutation Tests:
src/Manager/ScreenManager.php#L26
Escaped Mutant for Mutator "Concat":
@@ @@
}
public function generateScreenName(ScreenInterface $screen): string
{
- return hash('sha256', $this->getBaseDirectory() . $screen->getName() . implode('', $screen->getCommand()));
+ return hash('sha256', $this->getBaseDirectory() . implode('', $screen->getCommand()) . $screen->getName());
}
private function getLogDirectory(): string
{
|