Continuous Integration #1513
continuous-integration.yml
on: create
run
/
Generate test matrix
2s
Matrix: run / Code Coverage
Matrix: run / Coding Standards
Matrix: run / Lint composer.json
Matrix: run / Lint symfony container
Matrix: run / Mutation Tests
Matrix: run / Static Code Analysis
Matrix: run / Lint twig files
Matrix: run / Lint XLIFF files
Matrix: run / Lint YML files
Matrix: run / tests
Annotations
10 warnings
run / Mutation Tests (8.2):
src/Extension/UrlAutoConverterExtension.php#L23
Escaped Mutant for Mutator "ArrayItemRemoval":
--- Original
+++ New
@@ @@
{
public function getFilters() : array
{
- return [new TwigFilter('converturls', [UrlAutoConverterRuntime::class, 'convertLinks'], ['is_safe' => ['html']])];
+ return [new TwigFilter('converturls', [UrlAutoConverterRuntime::class, 'convertLinks'], ['is_safe' => []])];
}
}
|
run / Mutation Tests (8.2):
src/Extension/UrlAutoConverterExtension.php#L23
Escaped Mutant for Mutator "ArrayItemRemoval":
--- Original
+++ New
@@ @@
{
public function getFilters() : array
{
- return [new TwigFilter('converturls', [UrlAutoConverterRuntime::class, 'convertLinks'], ['is_safe' => ['html']])];
+ return [new TwigFilter('converturls', [UrlAutoConverterRuntime::class, 'convertLinks'], [])];
}
}
|
run / Mutation Tests (8.2):
src/Runtime/RouterRuntime.php#L34
Escaped Mutant for Mutator "UnwrapTrim":
--- Original
+++ New
@@ @@
*/
public function splitTag(string $text, string $tag) : array
{
- if ('' === trim($tag)) {
+ if ('' === $tag) {
return [$text];
}
$split = preg_split('/(?=<' . $tag . '([^>])*>)/', $text, -1, PREG_SPLIT_NO_EMPTY | PREG_SPLIT_DELIM_CAPTURE);
|
run / Mutation Tests (8.2):
src/Runtime/RouterRuntime.php#L40
Escaped Mutant for Mutator "FalseValue":
--- Original
+++ New
@@ @@
return [$text];
}
$split = preg_split('/(?=<' . $tag . '([^>])*>)/', $text, -1, PREG_SPLIT_NO_EMPTY | PREG_SPLIT_DELIM_CAPTURE);
- if (false !== $split) {
+ if (true !== $split) {
return $split;
}
return [$text];
}
}
|
run / Mutation Tests (8.2):
src/Runtime/StringRuntime.php#L19
Escaped Mutant for Mutator "TrueValue":
--- Original
+++ New
@@ @@
use Twig\Extension\RuntimeExtensionInterface;
final class StringRuntime implements RuntimeExtensionInterface
{
- public function formatBytes(float $bytes, bool $si = true, int $fractionDigits = 0, ?string $locale = null) : string
+ public function formatBytes(float $bytes, bool $si = false, int $fractionDigits = 0, ?string $locale = null) : string
{
if (null === $locale) {
$locale = Locale::getDefault();
|
run / Mutation Tests (8.2):
src/Runtime/StringRuntime.php#L19
Escaped Mutant for Mutator "DecrementInteger":
--- Original
+++ New
@@ @@
use Twig\Extension\RuntimeExtensionInterface;
final class StringRuntime implements RuntimeExtensionInterface
{
- public function formatBytes(float $bytes, bool $si = true, int $fractionDigits = 0, ?string $locale = null) : string
+ public function formatBytes(float $bytes, bool $si = true, int $fractionDigits = -1, ?string $locale = null) : string
{
if (null === $locale) {
$locale = Locale::getDefault();
|
run / Mutation Tests (8.2):
src/Runtime/StringRuntime.php#L19
Escaped Mutant for Mutator "IncrementInteger":
--- Original
+++ New
@@ @@
use Twig\Extension\RuntimeExtensionInterface;
final class StringRuntime implements RuntimeExtensionInterface
{
- public function formatBytes(float $bytes, bool $si = true, int $fractionDigits = 0, ?string $locale = null) : string
+ public function formatBytes(float $bytes, bool $si = true, int $fractionDigits = 1, ?string $locale = null) : string
{
if (null === $locale) {
$locale = Locale::getDefault();
|
run / Mutation Tests (8.2):
src/Runtime/StringRuntime.php#L25
Escaped Mutant for Mutator "DecrementInteger":
--- Original
+++ New
@@ @@
if (null === $locale) {
$locale = Locale::getDefault();
}
- $unit = $si ? 1000 : 1024;
+ $unit = $si ? 999 : 1024;
if ($bytes < $unit) {
$prefix = '';
$number = $bytes;
|
run / Mutation Tests (8.2):
src/Runtime/StringRuntime.php#L25
Escaped Mutant for Mutator "DecrementInteger":
--- Original
+++ New
@@ @@
if (null === $locale) {
$locale = Locale::getDefault();
}
- $unit = $si ? 1000 : 1024;
+ $unit = $si ? 1000 : 1023;
if ($bytes < $unit) {
$prefix = '';
$number = $bytes;
|
run / Mutation Tests (8.2):
src/Runtime/StringRuntime.php#L38
Escaped Mutant for Mutator "MethodCallRemoval":
--- Original
+++ New
@@ @@
$number = $bytes / $unit ** $exp;
}
$formatter = new NumberFormatter($locale, NumberFormatter::DECIMAL);
- $formatter->setAttribute(NumberFormatter::MIN_FRACTION_DIGITS, $fractionDigits);
+
$formatter->setAttribute(NumberFormatter::FRACTION_DIGITS, $fractionDigits);
return sprintf('%s %sB', $formatter->format($number, NumberFormatter::TYPE_DEFAULT), $prefix);
}
|