Skip to content

Fix #592 - desc index #676

Fix #592 - desc index

Fix #592 - desc index #676

Re-run triggered November 25, 2025 20:39
Status Success
Total duration 1m 38s
Artifacts

mutation-tests.yml

on: pull_request
Matrix: tests
Fit to window
Zoom out
Zoom in

Annotations

10 warnings
Mutation tests with PHP 8.2: src/Parsers/AlterOperations.php#L412
Escaped Mutant for Mutator "LogicalAnd": @@ @@ $list->idx++; // Ignore the current token $nextToken = $list->getNext(); - if ($token->type === TokenType::Keyword && ($token->keyword === 'PARTITION BY' || $token->keyword === 'PARTITION' && $nextToken && $nextToken->value !== '(')) { + if ($token->type === TokenType::Keyword && ($token->keyword === 'PARTITION BY' || ($token->keyword === 'PARTITION' || $nextToken) && $nextToken->value !== '(')) { $partitionState = 1; } elseif ($token->type === TokenType::Keyword && $token->keyword === 'PARTITION') { $partitionState = 2;
Mutation tests with PHP 8.2: src/Parsers/AlterOperations.php#L380
Escaped Mutant for Mutator "LogicalAnd": @@ @@ if ($token->value === 'SET' && $nextToken !== null && $nextToken->value === '(') { // To avoid adding the tokens between the SET() parentheses to the unknown tokens $list->getNextOfTypeAndValue(TokenType::Operator, ')'); - } elseif ($token->value === 'SET' && $nextToken !== null && $nextToken->value === 'DEFAULT') { + } elseif (($token->value === 'SET' || $nextToken !== null) && $nextToken->value === 'DEFAULT') { // to avoid adding the `DEFAULT` token to the unknown tokens. ++$list->idx; } else {
Mutation tests with PHP 8.2: src/Parsers/AlterOperations.php#L358
Escaped Mutant for Mutator "LogicalOrSingleSubExprNegation": @@ @@ } $state = 2; } elseif ($state === 2) { - if (is_string($token->value) || is_int($token->value)) { + if (is_string($token->value) || !is_int($token->value)) { $arrayKey = $token->value; } else { $arrayKey = $token->token;
Mutation tests with PHP 8.2: src/Parsers/AlterOperations.php#L358
Escaped Mutant for Mutator "LogicalOrSingleSubExprNegation": @@ @@ } $state = 2; } elseif ($state === 2) { - if (is_string($token->value) || is_int($token->value)) { + if (!is_string($token->value) || is_int($token->value)) { $arrayKey = $token->value; } else { $arrayKey = $token->token;
Mutation tests with PHP 8.2: src/Parsers/AlterOperations.php#L358
Escaped Mutant for Mutator "LogicalOrNegation": @@ @@ } $state = 2; } elseif ($state === 2) { - if (is_string($token->value) || is_int($token->value)) { + if (!(is_string($token->value) || is_int($token->value))) { $arrayKey = $token->value; } else { $arrayKey = $token->token;
Mutation tests with PHP 8.2: src/Parsers/AlterOperations.php#L358
Escaped Mutant for Mutator "LogicalOrAllSubExprNegation": @@ @@ } $state = 2; } elseif ($state === 2) { - if (is_string($token->value) || is_int($token->value)) { + if (!is_string($token->value) || !is_int($token->value)) { $arrayKey = $token->value; } else { $arrayKey = $token->token;
Mutation tests with PHP 8.2: src/Parsers/AlterOperations.php#L358
Escaped Mutant for Mutator "LogicalOr": @@ @@ } $state = 2; } elseif ($state === 2) { - if (is_string($token->value) || is_int($token->value)) { + if (is_string($token->value) && is_int($token->value)) { $arrayKey = $token->value; } else { $arrayKey = $token->token;
Mutation tests with PHP 8.2: src/Parsers/AlterOperations.php#L318
Escaped Mutant for Mutator "LessThan": @@ @@ // Not only when aliasing but also when parsing the body of an event, we just list the tokens of the // body in the unknown tokens list, as they define their own statements. if ($ret->options->has('AS') || $ret->options->has('DO')) { - for (; $list->idx < $list->count; ++$list->idx) { + for (; $list->idx <= $list->count; ++$list->idx) { if ($list->tokens[$list->idx]->type === TokenType::Delimiter) { break; }
Mutation tests with PHP 8.2: src/Parsers/AlterOperations.php#L304
Escaped Mutant for Mutator "DecrementInteger": @@ @@ } // Skipping whitespaces. if ($token->type === TokenType::Whitespace) { - if ($state === 2) { + if ($state === 1) { // When parsing the unknown part, the whitespaces are // included to not break anything. $ret->unknown[] = $token;
Mutation tests with PHP 8.2: src/Parsers/AlterOperations.php#L299
Escaped Mutant for Mutator "Continue_": @@ @@ } // Skipping comments. if ($token->type === TokenType::Comment) { - continue; + break; } // Skipping whitespaces. if ($token->type === TokenType::Whitespace) {