diff --git a/.php-cs-fixer.dist.php b/.php-cs-fixer.dist.php index b94af5ce..84a8a511 100644 --- a/.php-cs-fixer.dist.php +++ b/.php-cs-fixer.dist.php @@ -61,9 +61,15 @@ 'yield', ], ], - 'braces' => [ - 'position_after_anonymous_constructs' => 'next', + 'single_space_around_construct' => true, + 'control_structure_braces' => true, + 'control_structure_continuation_position' => true, + 'declare_parentheses' => true, + 'no_multiple_statements_per_line' => true, + 'braces_position' => [ + 'anonymous_classes_opening_brace' => 'next_line_unless_newline_at_signature_end', ], + 'statement_indentation' => true, 'cast_spaces' => true, 'class_attributes_separation' => [ 'elements' => [ @@ -77,7 +83,7 @@ 'combine_consecutive_issets' => true, 'combine_consecutive_unsets' => true, 'combine_nested_dirname' => true, - 'compact_nullable_typehint' => true, + 'compact_nullable_type_declaration' => true, 'concat_space' => ['spacing' => 'one'], 'constant_case' => true, 'declare_equal_normalize' => ['space' => 'none'], @@ -126,12 +132,12 @@ 'native_constant_invocation' => false, 'native_function_casing' => false, 'native_function_invocation' => false, - 'native_function_type_declaration_casing' => true, + 'native_type_declaration_casing' => true, 'no_alias_functions' => true, 'no_alias_language_construct_call' => true, 'no_blank_lines_after_class_opening' => true, 'no_blank_lines_after_phpdoc' => true, - 'no_blank_lines_before_namespace' => true, + 'blank_lines_before_namespace' => true, 'no_break_comment' => true, 'no_closing_tag' => true, 'no_empty_comment' => true, @@ -146,18 +152,17 @@ 'no_singleline_whitespace_before_semicolons' => true, 'no_spaces_after_function_name' => true, 'no_spaces_around_offset' => true, - 'no_spaces_inside_parenthesis' => true, + 'spaces_inside_parentheses' => true, 'no_superfluous_elseif' => true, 'no_superfluous_phpdoc_tags' => [ 'allow_mixed' => true, ], - 'no_trailing_comma_in_list_call' => true, - 'no_trailing_comma_in_singleline_array' => true, + 'no_trailing_comma_in_singleline' => true, 'no_trailing_whitespace' => true, 'no_trailing_whitespace_in_comment' => true, 'no_trailing_whitespace_in_string' => true, 'no_unneeded_control_parentheses' => true, - 'no_unneeded_curly_braces' => true, + 'no_unneeded_braces' => true, 'no_unneeded_final_method' => true, 'no_unreachable_default_argument_value' => true, 'no_unset_cast' => true, @@ -270,13 +275,7 @@ 'trailing_comma_in_multiline' => true, 'trim_array_spaces' => true, 'unary_operator_spaces' => true, - 'visibility_required' => [ - 'elements' => [ - 'const', - 'method', - 'property', - ], - ], + 'modifier_keywords' => true, 'void_return' => true, 'whitespace_after_comma_in_array' => true, 'yoda_style' => [ diff --git a/CHANGELOG.md b/CHANGELOG.md index e338e42a..c6c7add7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,12 +8,17 @@ The format is based on [Keep a Changelog], and this project adheres to ## 7.0.0 - T.B.D. +### Added + +- Added support for operator chaining (e.g. `a > b > c`). + ### Changed - Changed the minimum required PHP version to 8.1. - Changed the signature of many functions to use PHP 8 union types. - Changed the `Relationship::DIR_*` to the `Direction` enum. - Remove `$insertParentheses` from all methods, and automatically insert them based on precedence. +- No longer insert parentheses when chaining comparison operators. ### Removed diff --git a/src/Clauses/CallClause.php b/src/Clauses/CallClause.php index 3182fc77..31356eb4 100644 --- a/src/Clauses/CallClause.php +++ b/src/Clauses/CallClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Expressions\Variable; diff --git a/src/Clauses/CallProcedureClause.php b/src/Clauses/CallProcedureClause.php index be5ccc17..513bb963 100644 --- a/src/Clauses/CallProcedureClause.php +++ b/src/Clauses/CallProcedureClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Expressions\Procedures\Procedure; diff --git a/src/Clauses/Clause.php b/src/Clauses/Clause.php index 3aeceeef..5b292ae5 100644 --- a/src/Clauses/Clause.php +++ b/src/Clauses/Clause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\QueryConvertible; diff --git a/src/Clauses/CreateClause.php b/src/Clauses/CreateClause.php index f305b4b2..04ef27f5 100644 --- a/src/Clauses/CreateClause.php +++ b/src/Clauses/CreateClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Patterns\CompletePattern; diff --git a/src/Clauses/DeleteClause.php b/src/Clauses/DeleteClause.php index b8aeff5b..64a746d7 100644 --- a/src/Clauses/DeleteClause.php +++ b/src/Clauses/DeleteClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Patterns\Pattern; diff --git a/src/Clauses/LimitClause.php b/src/Clauses/LimitClause.php index 18b900aa..b3ff7695 100644 --- a/src/Clauses/LimitClause.php +++ b/src/Clauses/LimitClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Query; diff --git a/src/Clauses/MatchClause.php b/src/Clauses/MatchClause.php index 8615daed..f5ae82e0 100644 --- a/src/Clauses/MatchClause.php +++ b/src/Clauses/MatchClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Patterns\CompletePattern; diff --git a/src/Clauses/MergeClause.php b/src/Clauses/MergeClause.php index 6f002ef1..234baa26 100644 --- a/src/Clauses/MergeClause.php +++ b/src/Clauses/MergeClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Patterns\CompletePattern; diff --git a/src/Clauses/OptionalMatchClause.php b/src/Clauses/OptionalMatchClause.php index 30d473a8..88e51b8e 100644 --- a/src/Clauses/OptionalMatchClause.php +++ b/src/Clauses/OptionalMatchClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Patterns\CompletePattern; diff --git a/src/Clauses/OrderByClause.php b/src/Clauses/OrderByClause.php index 91f4e970..219286d2 100644 --- a/src/Clauses/OrderByClause.php +++ b/src/Clauses/OrderByClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Expressions\Property; diff --git a/src/Clauses/RawClause.php b/src/Clauses/RawClause.php index d40d79b3..6cc9d6ad 100644 --- a/src/Clauses/RawClause.php +++ b/src/Clauses/RawClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; /** diff --git a/src/Clauses/RemoveClause.php b/src/Clauses/RemoveClause.php index b28665ff..3209722a 100644 --- a/src/Clauses/RemoveClause.php +++ b/src/Clauses/RemoveClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Expressions\Label; diff --git a/src/Clauses/ReturnClause.php b/src/Clauses/ReturnClause.php index 76986a33..d5fba0a1 100644 --- a/src/Clauses/ReturnClause.php +++ b/src/Clauses/ReturnClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Patterns\Pattern; diff --git a/src/Clauses/SetClause.php b/src/Clauses/SetClause.php index 19be1ca7..0473f976 100644 --- a/src/Clauses/SetClause.php +++ b/src/Clauses/SetClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Expressions\Label; diff --git a/src/Clauses/SkipClause.php b/src/Clauses/SkipClause.php index 3a7ae7b9..4f49a456 100644 --- a/src/Clauses/SkipClause.php +++ b/src/Clauses/SkipClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Types\PropertyTypes\IntegerType; diff --git a/src/Clauses/UnionClause.php b/src/Clauses/UnionClause.php index aaed2301..0aa376e7 100644 --- a/src/Clauses/UnionClause.php +++ b/src/Clauses/UnionClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Query; diff --git a/src/Clauses/WhereClause.php b/src/Clauses/WhereClause.php index c634e27c..b4f75240 100644 --- a/src/Clauses/WhereClause.php +++ b/src/Clauses/WhereClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use InvalidArgumentException; diff --git a/src/Clauses/WithClause.php b/src/Clauses/WithClause.php index 7332e4a2..4f3c6af1 100644 --- a/src/Clauses/WithClause.php +++ b/src/Clauses/WithClause.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Clauses; use WikibaseSolutions\CypherDSL\Expressions\Variable; diff --git a/src/Expressions/Exists.php b/src/Expressions/Exists.php index 38bb60c0..a6fa0d39 100644 --- a/src/Expressions/Exists.php +++ b/src/Expressions/Exists.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions; use WikibaseSolutions\CypherDSL\Clauses\MatchClause; diff --git a/src/Expressions/Label.php b/src/Expressions/Label.php index d85bb462..e0c1a5f8 100644 --- a/src/Expressions/Label.php +++ b/src/Expressions/Label.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\BooleanTypeTrait; diff --git a/src/Expressions/Literals/Boolean.php b/src/Expressions/Literals/Boolean.php index 08523b9d..32a62264 100644 --- a/src/Expressions/Literals/Boolean.php +++ b/src/Expressions/Literals/Boolean.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Literals; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\BooleanTypeTrait; diff --git a/src/Expressions/Literals/Float_.php b/src/Expressions/Literals/Float_.php index 3c579f9f..826c9352 100644 --- a/src/Expressions/Literals/Float_.php +++ b/src/Expressions/Literals/Float_.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Literals; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\FloatTypeTrait; diff --git a/src/Expressions/Literals/Integer.php b/src/Expressions/Literals/Integer.php index ad9d8e4b..56213ee1 100644 --- a/src/Expressions/Literals/Integer.php +++ b/src/Expressions/Literals/Integer.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Literals; use TypeError; diff --git a/src/Expressions/Literals/List_.php b/src/Expressions/Literals/List_.php index 63c91262..a5005c76 100644 --- a/src/Expressions/Literals/List_.php +++ b/src/Expressions/Literals/List_.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Literals; use WikibaseSolutions\CypherDSL\Patterns\Pattern; diff --git a/src/Expressions/Literals/Literal.php b/src/Expressions/Literals/Literal.php index 94f87463..2c6d8b46 100644 --- a/src/Expressions/Literals/Literal.php +++ b/src/Expressions/Literals/Literal.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Literals; use LogicException; diff --git a/src/Expressions/Literals/Map.php b/src/Expressions/Literals/Map.php index 6b1c0382..300dc18d 100644 --- a/src/Expressions/Literals/Map.php +++ b/src/Expressions/Literals/Map.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Literals; use Stringable; diff --git a/src/Expressions/Literals/String_.php b/src/Expressions/Literals/String_.php index 170b063e..494fbb31 100644 --- a/src/Expressions/Literals/String_.php +++ b/src/Expressions/Literals/String_.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Literals; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\StringTypeTrait; diff --git a/src/Expressions/Operators/Addition.php b/src/Expressions/Operators/Addition.php index a6b169a9..d1c5906e 100644 --- a/src/Expressions/Operators/Addition.php +++ b/src/Expressions/Operators/Addition.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/BinaryOperator.php b/src/Expressions/Operators/BinaryOperator.php index 6d9665ca..1fc24f28 100644 --- a/src/Expressions/Operators/BinaryOperator.php +++ b/src/Expressions/Operators/BinaryOperator.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; use WikibaseSolutions\CypherDSL\Types\AnyType; diff --git a/src/Expressions/Operators/BooleanBinaryOperator.php b/src/Expressions/Operators/BooleanBinaryOperator.php index b05421d1..e7cda205 100644 --- a/src/Expressions/Operators/BooleanBinaryOperator.php +++ b/src/Expressions/Operators/BooleanBinaryOperator.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\BooleanTypeTrait; diff --git a/src/Expressions/Operators/BooleanUnaryOperator.php b/src/Expressions/Operators/BooleanUnaryOperator.php index 71160515..5a4ee951 100644 --- a/src/Expressions/Operators/BooleanUnaryOperator.php +++ b/src/Expressions/Operators/BooleanUnaryOperator.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\BooleanTypeTrait; diff --git a/src/Expressions/Operators/ComparisonBinaryOperator.php b/src/Expressions/Operators/ComparisonBinaryOperator.php index 2538c306..9a607449 100644 --- a/src/Expressions/Operators/ComparisonBinaryOperator.php +++ b/src/Expressions/Operators/ComparisonBinaryOperator.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\BooleanTypeTrait; @@ -45,4 +46,16 @@ public function __construct(AnyType $left, AnyType $right) { parent::__construct($left, $right); } + + /** + * @inheritDoc + */ + protected function shouldInsertParentheses(AnyType $expression): bool + { + if ($expression instanceof self) { + return false; + } + + return parent::shouldInsertParentheses($expression); + } } diff --git a/src/Expressions/Operators/ComparisonUnaryOperator.php b/src/Expressions/Operators/ComparisonUnaryOperator.php index 41fbdac6..ea747157 100644 --- a/src/Expressions/Operators/ComparisonUnaryOperator.php +++ b/src/Expressions/Operators/ComparisonUnaryOperator.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\BooleanTypeTrait; diff --git a/src/Expressions/Operators/Conjunction.php b/src/Expressions/Operators/Conjunction.php index 996a850d..badef98a 100644 --- a/src/Expressions/Operators/Conjunction.php +++ b/src/Expressions/Operators/Conjunction.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/Contains.php b/src/Expressions/Operators/Contains.php index e16468d8..c17091d7 100644 --- a/src/Expressions/Operators/Contains.php +++ b/src/Expressions/Operators/Contains.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/Disjunction.php b/src/Expressions/Operators/Disjunction.php index 3885dba8..afe40230 100644 --- a/src/Expressions/Operators/Disjunction.php +++ b/src/Expressions/Operators/Disjunction.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/Division.php b/src/Expressions/Operators/Division.php index b2aacaec..c8bec6fe 100644 --- a/src/Expressions/Operators/Division.php +++ b/src/Expressions/Operators/Division.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/EndsWith.php b/src/Expressions/Operators/EndsWith.php index 147d7195..b1b56a71 100644 --- a/src/Expressions/Operators/EndsWith.php +++ b/src/Expressions/Operators/EndsWith.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/Equality.php b/src/Expressions/Operators/Equality.php index 9d2f0174..c4e7490e 100644 --- a/src/Expressions/Operators/Equality.php +++ b/src/Expressions/Operators/Equality.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/ExclusiveDisjunction.php b/src/Expressions/Operators/ExclusiveDisjunction.php index 9b475273..b4c3d044 100644 --- a/src/Expressions/Operators/ExclusiveDisjunction.php +++ b/src/Expressions/Operators/ExclusiveDisjunction.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/Exponentiation.php b/src/Expressions/Operators/Exponentiation.php index e9ff53b6..36f9b2f9 100644 --- a/src/Expressions/Operators/Exponentiation.php +++ b/src/Expressions/Operators/Exponentiation.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/GreaterThan.php b/src/Expressions/Operators/GreaterThan.php index 3f479dd9..81f121f9 100644 --- a/src/Expressions/Operators/GreaterThan.php +++ b/src/Expressions/Operators/GreaterThan.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/GreaterThanOrEqual.php b/src/Expressions/Operators/GreaterThanOrEqual.php index 271da14f..9953abb8 100644 --- a/src/Expressions/Operators/GreaterThanOrEqual.php +++ b/src/Expressions/Operators/GreaterThanOrEqual.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/In.php b/src/Expressions/Operators/In.php index 8a2caecb..cb6ff0f6 100644 --- a/src/Expressions/Operators/In.php +++ b/src/Expressions/Operators/In.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\BooleanTypeTrait; diff --git a/src/Expressions/Operators/Inequality.php b/src/Expressions/Operators/Inequality.php index a39d8b12..9cb2d5a7 100644 --- a/src/Expressions/Operators/Inequality.php +++ b/src/Expressions/Operators/Inequality.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/IsNotNull.php b/src/Expressions/Operators/IsNotNull.php index effa376f..fb180fff 100644 --- a/src/Expressions/Operators/IsNotNull.php +++ b/src/Expressions/Operators/IsNotNull.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/IsNull.php b/src/Expressions/Operators/IsNull.php index 0736c66b..999424e6 100644 --- a/src/Expressions/Operators/IsNull.php +++ b/src/Expressions/Operators/IsNull.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/LessThan.php b/src/Expressions/Operators/LessThan.php index 6596a28b..2df889b5 100644 --- a/src/Expressions/Operators/LessThan.php +++ b/src/Expressions/Operators/LessThan.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/LessThanOrEqual.php b/src/Expressions/Operators/LessThanOrEqual.php index 91f1a33a..ea04f1a3 100644 --- a/src/Expressions/Operators/LessThanOrEqual.php +++ b/src/Expressions/Operators/LessThanOrEqual.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/MathematicalBinaryOperator.php b/src/Expressions/Operators/MathematicalBinaryOperator.php index 41f3db08..ad45c2f5 100644 --- a/src/Expressions/Operators/MathematicalBinaryOperator.php +++ b/src/Expressions/Operators/MathematicalBinaryOperator.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\NumeralTypeTrait; diff --git a/src/Expressions/Operators/MathematicalUnaryOperator.php b/src/Expressions/Operators/MathematicalUnaryOperator.php index a7ba4e9e..09553e09 100644 --- a/src/Expressions/Operators/MathematicalUnaryOperator.php +++ b/src/Expressions/Operators/MathematicalUnaryOperator.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\NumeralTypeTrait; diff --git a/src/Expressions/Operators/ModuloDivision.php b/src/Expressions/Operators/ModuloDivision.php index 0a2ba1c8..0c29bc59 100644 --- a/src/Expressions/Operators/ModuloDivision.php +++ b/src/Expressions/Operators/ModuloDivision.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/Multiplication.php b/src/Expressions/Operators/Multiplication.php index 69e4afa8..7d513c47 100644 --- a/src/Expressions/Operators/Multiplication.php +++ b/src/Expressions/Operators/Multiplication.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/Negation.php b/src/Expressions/Operators/Negation.php index bc635127..c680037b 100644 --- a/src/Expressions/Operators/Negation.php +++ b/src/Expressions/Operators/Negation.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/Operator.php b/src/Expressions/Operators/Operator.php index 22d754d9..ddcb8f21 100644 --- a/src/Expressions/Operators/Operator.php +++ b/src/Expressions/Operators/Operator.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; use WikibaseSolutions\CypherDSL\QueryConvertible; @@ -38,7 +39,7 @@ abstract protected function getPrecedence(): Precedence; /** * Whether to insert parentheses around the given expression, given the precedence of this operator. */ - final protected function shouldInsertParentheses(AnyType $expression): bool + protected function shouldInsertParentheses(AnyType $expression): bool { if (!$expression instanceof self) { return false; diff --git a/src/Expressions/Operators/Precedence.php b/src/Expressions/Operators/Precedence.php index b5ba5ba4..4b4caecf 100644 --- a/src/Expressions/Operators/Precedence.php +++ b/src/Expressions/Operators/Precedence.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; enum Precedence: int diff --git a/src/Expressions/Operators/Regex.php b/src/Expressions/Operators/Regex.php index 9b651e4f..98786819 100644 --- a/src/Expressions/Operators/Regex.php +++ b/src/Expressions/Operators/Regex.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/StartsWith.php b/src/Expressions/Operators/StartsWith.php index ea6b25c6..9a4f813d 100644 --- a/src/Expressions/Operators/StartsWith.php +++ b/src/Expressions/Operators/StartsWith.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/StringSpecificComparisonBinaryOperator.php b/src/Expressions/Operators/StringSpecificComparisonBinaryOperator.php index 0eeaf122..68eeca6b 100644 --- a/src/Expressions/Operators/StringSpecificComparisonBinaryOperator.php +++ b/src/Expressions/Operators/StringSpecificComparisonBinaryOperator.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\BooleanTypeTrait; diff --git a/src/Expressions/Operators/Subtraction.php b/src/Expressions/Operators/Subtraction.php index 2e88da37..0eda746e 100644 --- a/src/Expressions/Operators/Subtraction.php +++ b/src/Expressions/Operators/Subtraction.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/UnaryMinus.php b/src/Expressions/Operators/UnaryMinus.php index a26c1eb0..493c4db4 100644 --- a/src/Expressions/Operators/UnaryMinus.php +++ b/src/Expressions/Operators/UnaryMinus.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; /** diff --git a/src/Expressions/Operators/UnaryOperator.php b/src/Expressions/Operators/UnaryOperator.php index 140528fe..6806b8dc 100644 --- a/src/Expressions/Operators/UnaryOperator.php +++ b/src/Expressions/Operators/UnaryOperator.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Operators; use WikibaseSolutions\CypherDSL\Types\AnyType; diff --git a/src/Expressions/Parameter.php b/src/Expressions/Parameter.php index 2ab2789b..1f6d1c8b 100644 --- a/src/Expressions/Parameter.php +++ b/src/Expressions/Parameter.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\CompositeTypeTraits\ListTypeTrait; diff --git a/src/Expressions/Procedures/All.php b/src/Expressions/Procedures/All.php index f78a336b..3e35d213 100644 --- a/src/Expressions/Procedures/All.php +++ b/src/Expressions/Procedures/All.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Procedures; use WikibaseSolutions\CypherDSL\Expressions\Variable; diff --git a/src/Expressions/Procedures/Any.php b/src/Expressions/Procedures/Any.php index 7dad6909..6029802e 100644 --- a/src/Expressions/Procedures/Any.php +++ b/src/Expressions/Procedures/Any.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Procedures; use WikibaseSolutions\CypherDSL\Expressions\Variable; diff --git a/src/Expressions/Procedures/Date.php b/src/Expressions/Procedures/Date.php index 6e63afc3..4bacedf3 100644 --- a/src/Expressions/Procedures/Date.php +++ b/src/Expressions/Procedures/Date.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Procedures; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\DateTypeTrait; diff --git a/src/Expressions/Procedures/DateTime.php b/src/Expressions/Procedures/DateTime.php index fe596102..325af190 100644 --- a/src/Expressions/Procedures/DateTime.php +++ b/src/Expressions/Procedures/DateTime.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Procedures; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\DateTimeTypeTrait; diff --git a/src/Expressions/Procedures/Exists.php b/src/Expressions/Procedures/Exists.php index 541d681f..04bb2de9 100644 --- a/src/Expressions/Procedures/Exists.php +++ b/src/Expressions/Procedures/Exists.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Procedures; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\BooleanTypeTrait; diff --git a/src/Expressions/Procedures/IsEmpty.php b/src/Expressions/Procedures/IsEmpty.php index 7cf7505f..3e460a64 100644 --- a/src/Expressions/Procedures/IsEmpty.php +++ b/src/Expressions/Procedures/IsEmpty.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Procedures; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\BooleanTypeTrait; diff --git a/src/Expressions/Procedures/LocalDateTime.php b/src/Expressions/Procedures/LocalDateTime.php index 8485c959..1004d39d 100644 --- a/src/Expressions/Procedures/LocalDateTime.php +++ b/src/Expressions/Procedures/LocalDateTime.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Procedures; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\LocalDateTimeTypeTrait; diff --git a/src/Expressions/Procedures/LocalTime.php b/src/Expressions/Procedures/LocalTime.php index da625d56..7684fa8b 100644 --- a/src/Expressions/Procedures/LocalTime.php +++ b/src/Expressions/Procedures/LocalTime.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Procedures; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\LocalTimeTypeTrait; diff --git a/src/Expressions/Procedures/None.php b/src/Expressions/Procedures/None.php index 34d1fcc1..1310a5ac 100644 --- a/src/Expressions/Procedures/None.php +++ b/src/Expressions/Procedures/None.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Procedures; use WikibaseSolutions\CypherDSL\Expressions\Variable; diff --git a/src/Expressions/Procedures/Point.php b/src/Expressions/Procedures/Point.php index 6706b811..6cc3d735 100644 --- a/src/Expressions/Procedures/Point.php +++ b/src/Expressions/Procedures/Point.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Procedures; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\PointTypeTrait; diff --git a/src/Expressions/Procedures/Procedure.php b/src/Expressions/Procedures/Procedure.php index 8d12b4da..ae4aa2b3 100644 --- a/src/Expressions/Procedures/Procedure.php +++ b/src/Expressions/Procedures/Procedure.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Procedures; use WikibaseSolutions\CypherDSL\Expressions\Literals\Literal; diff --git a/src/Expressions/Procedures/Raw.php b/src/Expressions/Procedures/Raw.php index f3f9a859..cc8951cf 100644 --- a/src/Expressions/Procedures/Raw.php +++ b/src/Expressions/Procedures/Raw.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Procedures; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\CompositeTypeTraits\ListTypeTrait; diff --git a/src/Expressions/Procedures/Single.php b/src/Expressions/Procedures/Single.php index 90923d8d..734dd49f 100644 --- a/src/Expressions/Procedures/Single.php +++ b/src/Expressions/Procedures/Single.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Procedures; use WikibaseSolutions\CypherDSL\Expressions\Variable; diff --git a/src/Expressions/Procedures/Time.php b/src/Expressions/Procedures/Time.php index f4873a34..f744202b 100644 --- a/src/Expressions/Procedures/Time.php +++ b/src/Expressions/Procedures/Time.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions\Procedures; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\TimeTypeTrait; diff --git a/src/Expressions/Property.php b/src/Expressions/Property.php index b97fdf82..f5b8ef54 100644 --- a/src/Expressions/Property.php +++ b/src/Expressions/Property.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions; use WikibaseSolutions\CypherDSL\Syntax\PropertyReplacement; diff --git a/src/Expressions/RawExpression.php b/src/Expressions/RawExpression.php index 137dac24..2fdaac81 100644 --- a/src/Expressions/RawExpression.php +++ b/src/Expressions/RawExpression.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\CompositeTypeTraits\ListTypeTrait; diff --git a/src/Expressions/Variable.php b/src/Expressions/Variable.php index 4eaac110..13a79771 100644 --- a/src/Expressions/Variable.php +++ b/src/Expressions/Variable.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Expressions; use WikibaseSolutions\CypherDSL\Expressions\Literals\Map; diff --git a/src/Patterns/CompletePattern.php b/src/Patterns/CompletePattern.php index 5a968d7b..77c73596 100644 --- a/src/Patterns/CompletePattern.php +++ b/src/Patterns/CompletePattern.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Patterns; /** diff --git a/src/Patterns/Direction.php b/src/Patterns/Direction.php index 6b7bf958..bb93186e 100644 --- a/src/Patterns/Direction.php +++ b/src/Patterns/Direction.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Patterns; /* diff --git a/src/Patterns/Node.php b/src/Patterns/Node.php index cb8538d7..1c1bd4b4 100644 --- a/src/Patterns/Node.php +++ b/src/Patterns/Node.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Patterns; use WikibaseSolutions\CypherDSL\Expressions\Label; diff --git a/src/Patterns/Path.php b/src/Patterns/Path.php index 36c1714a..8e5cc34d 100644 --- a/src/Patterns/Path.php +++ b/src/Patterns/Path.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Patterns; use WikibaseSolutions\CypherDSL\Expressions\Variable; diff --git a/src/Patterns/Pattern.php b/src/Patterns/Pattern.php index 0fe27291..08828900 100644 --- a/src/Patterns/Pattern.php +++ b/src/Patterns/Pattern.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Patterns; use WikibaseSolutions\CypherDSL\Expressions\Variable; diff --git a/src/Patterns/PropertyPattern.php b/src/Patterns/PropertyPattern.php index 55fbf6be..972e53dc 100644 --- a/src/Patterns/PropertyPattern.php +++ b/src/Patterns/PropertyPattern.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Patterns; use Stringable; diff --git a/src/Patterns/RelatablePattern.php b/src/Patterns/RelatablePattern.php index b61ec3ae..ead49e84 100644 --- a/src/Patterns/RelatablePattern.php +++ b/src/Patterns/RelatablePattern.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Patterns; use WikibaseSolutions\CypherDSL\Expressions\Variable; diff --git a/src/Patterns/Relationship.php b/src/Patterns/Relationship.php index 13a49be5..c702d6ed 100644 --- a/src/Patterns/Relationship.php +++ b/src/Patterns/Relationship.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Patterns; use DomainException; diff --git a/src/Query.php b/src/Query.php index 4dc8d786..03f11a31 100644 --- a/src/Query.php +++ b/src/Query.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL; use Stringable; diff --git a/src/QueryConvertible.php b/src/QueryConvertible.php index c9ce5255..614db0f0 100644 --- a/src/QueryConvertible.php +++ b/src/QueryConvertible.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL; /** diff --git a/src/Syntax/Alias.php b/src/Syntax/Alias.php index 705d7920..9c55d3af 100644 --- a/src/Syntax/Alias.php +++ b/src/Syntax/Alias.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Syntax; use WikibaseSolutions\CypherDSL\Expressions\Variable; diff --git a/src/Syntax/PropertyReplacement.php b/src/Syntax/PropertyReplacement.php index b1085e80..95677e05 100644 --- a/src/Syntax/PropertyReplacement.php +++ b/src/Syntax/PropertyReplacement.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Syntax; use WikibaseSolutions\CypherDSL\Expressions\Property; diff --git a/src/Traits/PatternTraits/PatternTrait.php b/src/Traits/PatternTraits/PatternTrait.php index bc40b8b6..7947c836 100644 --- a/src/Traits/PatternTraits/PatternTrait.php +++ b/src/Traits/PatternTraits/PatternTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\PatternTraits; use WikibaseSolutions\CypherDSL\Expressions\Variable; diff --git a/src/Traits/PatternTraits/PropertyPatternTrait.php b/src/Traits/PatternTraits/PropertyPatternTrait.php index 80dda049..c74be027 100644 --- a/src/Traits/PatternTraits/PropertyPatternTrait.php +++ b/src/Traits/PatternTraits/PropertyPatternTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\PatternTraits; use Stringable; @@ -66,8 +67,7 @@ public function addProperties(Map|array $properties): self $map = $this->makeMap(); if (is_array($properties)) { - $res = array_map(static function ($property) - { + $res = array_map(static function ($property) { return CastUtils::toAnyType($property); }, $properties); diff --git a/src/Traits/TypeTraits/AnyTypeTrait.php b/src/Traits/TypeTraits/AnyTypeTrait.php index d0aa0514..1fe8847a 100644 --- a/src/Traits/TypeTraits/AnyTypeTrait.php +++ b/src/Traits/TypeTraits/AnyTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits; use WikibaseSolutions\CypherDSL\Expressions\Operators\Equality; diff --git a/src/Traits/TypeTraits/CompositeTypeTraits/CompositeTypeTrait.php b/src/Traits/TypeTraits/CompositeTypeTraits/CompositeTypeTrait.php index 70c30255..395c1d1a 100644 --- a/src/Traits/TypeTraits/CompositeTypeTraits/CompositeTypeTrait.php +++ b/src/Traits/TypeTraits/CompositeTypeTraits/CompositeTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\CompositeTypeTraits; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\AnyTypeTrait; diff --git a/src/Traits/TypeTraits/CompositeTypeTraits/ListTypeTrait.php b/src/Traits/TypeTraits/CompositeTypeTraits/ListTypeTrait.php index ad1179b5..55427657 100644 --- a/src/Traits/TypeTraits/CompositeTypeTraits/ListTypeTrait.php +++ b/src/Traits/TypeTraits/CompositeTypeTraits/ListTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\CompositeTypeTraits; use WikibaseSolutions\CypherDSL\Expressions\Operators\In; diff --git a/src/Traits/TypeTraits/CompositeTypeTraits/MapTypeTrait.php b/src/Traits/TypeTraits/CompositeTypeTraits/MapTypeTrait.php index 3a6f2ddb..03114f4a 100644 --- a/src/Traits/TypeTraits/CompositeTypeTraits/MapTypeTrait.php +++ b/src/Traits/TypeTraits/CompositeTypeTraits/MapTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\CompositeTypeTraits; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\MethodTraits\PropertyMethodTrait; diff --git a/src/Traits/TypeTraits/MethodTraits/PropertyMethodTrait.php b/src/Traits/TypeTraits/MethodTraits/PropertyMethodTrait.php index 11f2c22d..6d89c40b 100644 --- a/src/Traits/TypeTraits/MethodTraits/PropertyMethodTrait.php +++ b/src/Traits/TypeTraits/MethodTraits/PropertyMethodTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\MethodTraits; use WikibaseSolutions\CypherDSL\Expressions\Property; diff --git a/src/Traits/TypeTraits/PropertyTypeTraits/BooleanTypeTrait.php b/src/Traits/TypeTraits/PropertyTypeTraits/BooleanTypeTrait.php index 8eb79f01..1b51847d 100644 --- a/src/Traits/TypeTraits/PropertyTypeTraits/BooleanTypeTrait.php +++ b/src/Traits/TypeTraits/PropertyTypeTraits/BooleanTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits; use WikibaseSolutions\CypherDSL\Expressions\Operators\Conjunction; diff --git a/src/Traits/TypeTraits/PropertyTypeTraits/DateTimeTypeTrait.php b/src/Traits/TypeTraits/PropertyTypeTraits/DateTimeTypeTrait.php index b47624ea..5de221cf 100644 --- a/src/Traits/TypeTraits/PropertyTypeTraits/DateTimeTypeTrait.php +++ b/src/Traits/TypeTraits/PropertyTypeTraits/DateTimeTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits; /** diff --git a/src/Traits/TypeTraits/PropertyTypeTraits/DateTypeTrait.php b/src/Traits/TypeTraits/PropertyTypeTraits/DateTypeTrait.php index d25e09db..101bae0b 100644 --- a/src/Traits/TypeTraits/PropertyTypeTraits/DateTypeTrait.php +++ b/src/Traits/TypeTraits/PropertyTypeTraits/DateTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits; /** diff --git a/src/Traits/TypeTraits/PropertyTypeTraits/FloatTypeTrait.php b/src/Traits/TypeTraits/PropertyTypeTraits/FloatTypeTrait.php index fbe5ed42..fa64fb95 100644 --- a/src/Traits/TypeTraits/PropertyTypeTraits/FloatTypeTrait.php +++ b/src/Traits/TypeTraits/PropertyTypeTraits/FloatTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits; /** diff --git a/src/Traits/TypeTraits/PropertyTypeTraits/IntegerTypeTrait.php b/src/Traits/TypeTraits/PropertyTypeTraits/IntegerTypeTrait.php index 1b1acdb1..acdf2343 100644 --- a/src/Traits/TypeTraits/PropertyTypeTraits/IntegerTypeTrait.php +++ b/src/Traits/TypeTraits/PropertyTypeTraits/IntegerTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits; /** diff --git a/src/Traits/TypeTraits/PropertyTypeTraits/LocalDateTimeTypeTrait.php b/src/Traits/TypeTraits/PropertyTypeTraits/LocalDateTimeTypeTrait.php index 7fb0b913..8f4a7e8c 100644 --- a/src/Traits/TypeTraits/PropertyTypeTraits/LocalDateTimeTypeTrait.php +++ b/src/Traits/TypeTraits/PropertyTypeTraits/LocalDateTimeTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits; /** diff --git a/src/Traits/TypeTraits/PropertyTypeTraits/LocalTimeTypeTrait.php b/src/Traits/TypeTraits/PropertyTypeTraits/LocalTimeTypeTrait.php index 84bafc5a..a025a3e0 100644 --- a/src/Traits/TypeTraits/PropertyTypeTraits/LocalTimeTypeTrait.php +++ b/src/Traits/TypeTraits/PropertyTypeTraits/LocalTimeTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits; /** diff --git a/src/Traits/TypeTraits/PropertyTypeTraits/NumeralTypeTrait.php b/src/Traits/TypeTraits/PropertyTypeTraits/NumeralTypeTrait.php index 6d674bf4..166cd705 100644 --- a/src/Traits/TypeTraits/PropertyTypeTraits/NumeralTypeTrait.php +++ b/src/Traits/TypeTraits/PropertyTypeTraits/NumeralTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits; use WikibaseSolutions\CypherDSL\Expressions\Operators\Addition; diff --git a/src/Traits/TypeTraits/PropertyTypeTraits/PointTypeTrait.php b/src/Traits/TypeTraits/PropertyTypeTraits/PointTypeTrait.php index c0f49966..0949d060 100644 --- a/src/Traits/TypeTraits/PropertyTypeTraits/PointTypeTrait.php +++ b/src/Traits/TypeTraits/PropertyTypeTraits/PointTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits; /** diff --git a/src/Traits/TypeTraits/PropertyTypeTraits/PropertyTypeTrait.php b/src/Traits/TypeTraits/PropertyTypeTraits/PropertyTypeTrait.php index e14136db..57f971e7 100644 --- a/src/Traits/TypeTraits/PropertyTypeTraits/PropertyTypeTrait.php +++ b/src/Traits/TypeTraits/PropertyTypeTraits/PropertyTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits; use WikibaseSolutions\CypherDSL\Expressions\Operators\In; diff --git a/src/Traits/TypeTraits/PropertyTypeTraits/StringTypeTrait.php b/src/Traits/TypeTraits/PropertyTypeTraits/StringTypeTrait.php index 432ebeb1..94a844a2 100644 --- a/src/Traits/TypeTraits/PropertyTypeTraits/StringTypeTrait.php +++ b/src/Traits/TypeTraits/PropertyTypeTraits/StringTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits; use WikibaseSolutions\CypherDSL\Expressions\Operators\Contains; diff --git a/src/Traits/TypeTraits/PropertyTypeTraits/TimeTypeTrait.php b/src/Traits/TypeTraits/PropertyTypeTraits/TimeTypeTrait.php index 7c281229..742e55a5 100644 --- a/src/Traits/TypeTraits/PropertyTypeTraits/TimeTypeTrait.php +++ b/src/Traits/TypeTraits/PropertyTypeTraits/TimeTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits; /** diff --git a/src/Traits/TypeTraits/StructuralTypeTraits/NodeTypeTrait.php b/src/Traits/TypeTraits/StructuralTypeTraits/NodeTypeTrait.php index d76fde3e..94d7ba37 100644 --- a/src/Traits/TypeTraits/StructuralTypeTraits/NodeTypeTrait.php +++ b/src/Traits/TypeTraits/StructuralTypeTraits/NodeTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\StructuralTypeTraits; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\MethodTraits\PropertyMethodTrait; diff --git a/src/Traits/TypeTraits/StructuralTypeTraits/PathTypeTrait.php b/src/Traits/TypeTraits/StructuralTypeTraits/PathTypeTrait.php index c1473a40..3da274bd 100644 --- a/src/Traits/TypeTraits/StructuralTypeTraits/PathTypeTrait.php +++ b/src/Traits/TypeTraits/StructuralTypeTraits/PathTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\StructuralTypeTraits; /** diff --git a/src/Traits/TypeTraits/StructuralTypeTraits/RelationshipTypeTrait.php b/src/Traits/TypeTraits/StructuralTypeTraits/RelationshipTypeTrait.php index 222ff499..d3175934 100644 --- a/src/Traits/TypeTraits/StructuralTypeTraits/RelationshipTypeTrait.php +++ b/src/Traits/TypeTraits/StructuralTypeTraits/RelationshipTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\StructuralTypeTraits; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\MethodTraits\PropertyMethodTrait; diff --git a/src/Traits/TypeTraits/StructuralTypeTraits/StructuralTypeTrait.php b/src/Traits/TypeTraits/StructuralTypeTraits/StructuralTypeTrait.php index 81a38816..cb9154f0 100644 --- a/src/Traits/TypeTraits/StructuralTypeTraits/StructuralTypeTrait.php +++ b/src/Traits/TypeTraits/StructuralTypeTraits/StructuralTypeTrait.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Traits\TypeTraits\StructuralTypeTraits; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\AnyTypeTrait; diff --git a/src/Types/AnyType.php b/src/Types/AnyType.php index 3ce50967..b0feecc6 100644 --- a/src/Types/AnyType.php +++ b/src/Types/AnyType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types; use WikibaseSolutions\CypherDSL\Expressions\Operators\Equality; diff --git a/src/Types/CompositeTypes/CompositeType.php b/src/Types/CompositeTypes/CompositeType.php index b0753cf8..2b4e5c72 100644 --- a/src/Types/CompositeTypes/CompositeType.php +++ b/src/Types/CompositeTypes/CompositeType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\CompositeTypes; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\CompositeTypeTraits\CompositeTypeTrait; diff --git a/src/Types/CompositeTypes/ListType.php b/src/Types/CompositeTypes/ListType.php index fc41e312..3912acd1 100644 --- a/src/Types/CompositeTypes/ListType.php +++ b/src/Types/CompositeTypes/ListType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\CompositeTypes; use WikibaseSolutions\CypherDSL\Expressions\Operators\In; diff --git a/src/Types/CompositeTypes/MapType.php b/src/Types/CompositeTypes/MapType.php index 1fc55b99..640cfd15 100644 --- a/src/Types/CompositeTypes/MapType.php +++ b/src/Types/CompositeTypes/MapType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\CompositeTypes; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\CompositeTypeTraits\MapTypeTrait; diff --git a/src/Types/Methods/PropertyMethod.php b/src/Types/Methods/PropertyMethod.php index 407aa0c6..9ebfc2fd 100644 --- a/src/Types/Methods/PropertyMethod.php +++ b/src/Types/Methods/PropertyMethod.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\Methods; use WikibaseSolutions\CypherDSL\Expressions\Property; diff --git a/src/Types/PropertyTypes/BooleanType.php b/src/Types/PropertyTypes/BooleanType.php index 576c3476..ca7b818e 100644 --- a/src/Types/PropertyTypes/BooleanType.php +++ b/src/Types/PropertyTypes/BooleanType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\PropertyTypes; use WikibaseSolutions\CypherDSL\Expressions\Operators\Conjunction; diff --git a/src/Types/PropertyTypes/DateTimeType.php b/src/Types/PropertyTypes/DateTimeType.php index 69557bc1..0b007ddb 100644 --- a/src/Types/PropertyTypes/DateTimeType.php +++ b/src/Types/PropertyTypes/DateTimeType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\PropertyTypes; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\DateTimeTypeTrait; diff --git a/src/Types/PropertyTypes/DateType.php b/src/Types/PropertyTypes/DateType.php index 76436a6b..17bfa927 100644 --- a/src/Types/PropertyTypes/DateType.php +++ b/src/Types/PropertyTypes/DateType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\PropertyTypes; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\DateTypeTrait; diff --git a/src/Types/PropertyTypes/FloatType.php b/src/Types/PropertyTypes/FloatType.php index dc29d40b..480cc917 100644 --- a/src/Types/PropertyTypes/FloatType.php +++ b/src/Types/PropertyTypes/FloatType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\PropertyTypes; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\FloatTypeTrait; diff --git a/src/Types/PropertyTypes/IntegerType.php b/src/Types/PropertyTypes/IntegerType.php index ab7177e0..19313edc 100644 --- a/src/Types/PropertyTypes/IntegerType.php +++ b/src/Types/PropertyTypes/IntegerType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\PropertyTypes; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\IntegerTypeTrait; diff --git a/src/Types/PropertyTypes/LocalDateTimeType.php b/src/Types/PropertyTypes/LocalDateTimeType.php index 55b36317..32dd3c8a 100644 --- a/src/Types/PropertyTypes/LocalDateTimeType.php +++ b/src/Types/PropertyTypes/LocalDateTimeType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\PropertyTypes; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\LocalDateTimeTypeTrait; diff --git a/src/Types/PropertyTypes/LocalTimeType.php b/src/Types/PropertyTypes/LocalTimeType.php index 54372dc6..49facaf7 100644 --- a/src/Types/PropertyTypes/LocalTimeType.php +++ b/src/Types/PropertyTypes/LocalTimeType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\PropertyTypes; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\LocalTimeTypeTrait; diff --git a/src/Types/PropertyTypes/NumeralType.php b/src/Types/PropertyTypes/NumeralType.php index ab8353e4..c5c1f37e 100644 --- a/src/Types/PropertyTypes/NumeralType.php +++ b/src/Types/PropertyTypes/NumeralType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\PropertyTypes; use WikibaseSolutions\CypherDSL\Expressions\Operators\Addition; diff --git a/src/Types/PropertyTypes/PointType.php b/src/Types/PropertyTypes/PointType.php index f83328e6..14243bcd 100644 --- a/src/Types/PropertyTypes/PointType.php +++ b/src/Types/PropertyTypes/PointType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\PropertyTypes; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\PointTypeTrait; diff --git a/src/Types/PropertyTypes/PropertyType.php b/src/Types/PropertyTypes/PropertyType.php index 25ea859a..c9d1fc86 100644 --- a/src/Types/PropertyTypes/PropertyType.php +++ b/src/Types/PropertyTypes/PropertyType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\PropertyTypes; use WikibaseSolutions\CypherDSL\Expressions\Operators\In; diff --git a/src/Types/PropertyTypes/StringType.php b/src/Types/PropertyTypes/StringType.php index ba5620e2..ba127844 100644 --- a/src/Types/PropertyTypes/StringType.php +++ b/src/Types/PropertyTypes/StringType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\PropertyTypes; use WikibaseSolutions\CypherDSL\Expressions\Operators\Contains; diff --git a/src/Types/PropertyTypes/TimeType.php b/src/Types/PropertyTypes/TimeType.php index 110cb002..f2d6b17e 100644 --- a/src/Types/PropertyTypes/TimeType.php +++ b/src/Types/PropertyTypes/TimeType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\PropertyTypes; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\PropertyTypeTraits\TimeTypeTrait; diff --git a/src/Types/StructuralTypes/NodeType.php b/src/Types/StructuralTypes/NodeType.php index c8d5794a..1f0d7f77 100644 --- a/src/Types/StructuralTypes/NodeType.php +++ b/src/Types/StructuralTypes/NodeType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\StructuralTypes; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\StructuralTypeTraits\NodeTypeTrait; diff --git a/src/Types/StructuralTypes/PathType.php b/src/Types/StructuralTypes/PathType.php index 989ab00c..60dc71c8 100644 --- a/src/Types/StructuralTypes/PathType.php +++ b/src/Types/StructuralTypes/PathType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\StructuralTypes; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\StructuralTypeTraits\PathTypeTrait; diff --git a/src/Types/StructuralTypes/RelationshipType.php b/src/Types/StructuralTypes/RelationshipType.php index 8a78ec85..1a686669 100644 --- a/src/Types/StructuralTypes/RelationshipType.php +++ b/src/Types/StructuralTypes/RelationshipType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\StructuralTypes; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\StructuralTypeTraits\RelationshipTypeTrait; diff --git a/src/Types/StructuralTypes/StructuralType.php b/src/Types/StructuralTypes/StructuralType.php index 4540a6cd..47deda9f 100644 --- a/src/Types/StructuralTypes/StructuralType.php +++ b/src/Types/StructuralTypes/StructuralType.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Types\StructuralTypes; use WikibaseSolutions\CypherDSL\Traits\TypeTraits\StructuralTypeTraits\StructuralTypeTrait; diff --git a/src/Utils/CastUtils.php b/src/Utils/CastUtils.php index 8e3d89e5..202f59d1 100644 --- a/src/Utils/CastUtils.php +++ b/src/Utils/CastUtils.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Utils; use Stringable; diff --git a/src/Utils/NameUtils.php b/src/Utils/NameUtils.php index 24db7c62..435defd9 100644 --- a/src/Utils/NameUtils.php +++ b/src/Utils/NameUtils.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Utils; use InvalidArgumentException; diff --git a/src/functions.php b/src/functions.php index a38dcdee..2b995861 100644 --- a/src/functions.php +++ b/src/functions.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL; use Stringable; diff --git a/tests/end-to-end/ExamplesTest.php b/tests/end-to-end/ExamplesTest.php index a6085eea..00292ee4 100644 --- a/tests/end-to-end/ExamplesTest.php +++ b/tests/end-to-end/ExamplesTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\EndToEnd; use PHPUnit\Framework\TestCase; @@ -48,8 +49,7 @@ public function testOldReadmeExample(): void public function testCallSubqueryClauseExample1(): void { $query = query() - ->call(static function (Query $query): void - { + ->call(static function (Query $query): void { $query->create(node("Person")); }) ->build(); @@ -72,8 +72,7 @@ public function testCallSubqueryClauseExample3(): void $person = variable(); $query = query() ->match(node('Person')->withVariable($person)) - ->call(static function (Query $query) use ($person): void - { + ->call(static function (Query $query) use ($person): void { $query->remove($person->labeled('Person')); }, [$person]) ->build(); diff --git a/tests/end-to-end/MoviesTest.php b/tests/end-to-end/MoviesTest.php index a2bbcfda..cf5756f0 100644 --- a/tests/end-to-end/MoviesTest.php +++ b/tests/end-to-end/MoviesTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\EndToEnd; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/CallClauseTest.php b/tests/unit/Clauses/CallClauseTest.php index 15bd27b2..e0d20e16 100644 --- a/tests/unit/Clauses/CallClauseTest.php +++ b/tests/unit/Clauses/CallClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/CallProcedureClauseTest.php b/tests/unit/Clauses/CallProcedureClauseTest.php index 38920c33..3a405bd8 100644 --- a/tests/unit/Clauses/CallProcedureClauseTest.php +++ b/tests/unit/Clauses/CallProcedureClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/ClauseTest.php b/tests/unit/Clauses/ClauseTest.php index 0e17b7e1..758190a8 100644 --- a/tests/unit/Clauses/ClauseTest.php +++ b/tests/unit/Clauses/ClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/CreateClauseTest.php b/tests/unit/Clauses/CreateClauseTest.php index 6f09d5e7..3c0eeec4 100644 --- a/tests/unit/Clauses/CreateClauseTest.php +++ b/tests/unit/Clauses/CreateClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/DeleteClauseTest.php b/tests/unit/Clauses/DeleteClauseTest.php index 115915c1..911ba8d6 100644 --- a/tests/unit/Clauses/DeleteClauseTest.php +++ b/tests/unit/Clauses/DeleteClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/LimitClauseTest.php b/tests/unit/Clauses/LimitClauseTest.php index a1a5b392..bce9f3b5 100644 --- a/tests/unit/Clauses/LimitClauseTest.php +++ b/tests/unit/Clauses/LimitClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/MatchClauseTest.php b/tests/unit/Clauses/MatchClauseTest.php index 0a42bcb0..46a98816 100644 --- a/tests/unit/Clauses/MatchClauseTest.php +++ b/tests/unit/Clauses/MatchClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/MergeClauseTest.php b/tests/unit/Clauses/MergeClauseTest.php index ac33129b..dee69d53 100644 --- a/tests/unit/Clauses/MergeClauseTest.php +++ b/tests/unit/Clauses/MergeClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/OptionalMatchTest.php b/tests/unit/Clauses/OptionalMatchTest.php index fb69502b..bdff365e 100644 --- a/tests/unit/Clauses/OptionalMatchTest.php +++ b/tests/unit/Clauses/OptionalMatchTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/OrderByClauseTest.php b/tests/unit/Clauses/OrderByClauseTest.php index 20565d8f..ab0392b5 100644 --- a/tests/unit/Clauses/OrderByClauseTest.php +++ b/tests/unit/Clauses/OrderByClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/RawClauseTest.php b/tests/unit/Clauses/RawClauseTest.php index 008dc6f6..52006886 100644 --- a/tests/unit/Clauses/RawClauseTest.php +++ b/tests/unit/Clauses/RawClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/RemoveClauseTest.php b/tests/unit/Clauses/RemoveClauseTest.php index 5e407948..9f336828 100644 --- a/tests/unit/Clauses/RemoveClauseTest.php +++ b/tests/unit/Clauses/RemoveClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/ReturnClauseTest.php b/tests/unit/Clauses/ReturnClauseTest.php index 7f8f515f..7c06cf2a 100644 --- a/tests/unit/Clauses/ReturnClauseTest.php +++ b/tests/unit/Clauses/ReturnClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/SetClauseTest.php b/tests/unit/Clauses/SetClauseTest.php index cb012305..ed0f7956 100644 --- a/tests/unit/Clauses/SetClauseTest.php +++ b/tests/unit/Clauses/SetClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/SkipClauseTest.php b/tests/unit/Clauses/SkipClauseTest.php index 8b64ae82..2a7c55d2 100644 --- a/tests/unit/Clauses/SkipClauseTest.php +++ b/tests/unit/Clauses/SkipClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/UnionClauseTest.php b/tests/unit/Clauses/UnionClauseTest.php index ae9fe310..c64b2c2a 100644 --- a/tests/unit/Clauses/UnionClauseTest.php +++ b/tests/unit/Clauses/UnionClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Clauses/WhereClauseTest.php b/tests/unit/Clauses/WhereClauseTest.php index 6e1b38cd..18350434 100644 --- a/tests/unit/Clauses/WhereClauseTest.php +++ b/tests/unit/Clauses/WhereClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use InvalidArgumentException; diff --git a/tests/unit/Clauses/WithClauseTest.php b/tests/unit/Clauses/WithClauseTest.php index 29f3ab44..126e73b1 100644 --- a/tests/unit/Clauses/WithClauseTest.php +++ b/tests/unit/Clauses/WithClauseTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Clauses; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/AliasTest.php b/tests/unit/Expressions/AliasTest.php index fafbc739..83b7218f 100644 --- a/tests/unit/Expressions/AliasTest.php +++ b/tests/unit/Expressions/AliasTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/ExistsTest.php b/tests/unit/Expressions/ExistsTest.php index 99812c1e..a691545d 100644 --- a/tests/unit/Expressions/ExistsTest.php +++ b/tests/unit/Expressions/ExistsTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions; use PHPUnit\Framework\TestCase; @@ -48,7 +49,7 @@ public function testToQuery(): void ) ), (new WhereClause)->addExpression( - new Equality(new Property(new Variable('toy'), 'name'), new String_('Banana'), false) + new Equality(new Property(new Variable('toy'), 'name'), new String_('Banana')) ) ); diff --git a/tests/unit/Expressions/LabelTest.php b/tests/unit/Expressions/LabelTest.php index 244717af..e9622c54 100644 --- a/tests/unit/Expressions/LabelTest.php +++ b/tests/unit/Expressions/LabelTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Literals/BooleanTest.php b/tests/unit/Expressions/Literals/BooleanTest.php index 26b23b5e..d503bcf1 100644 --- a/tests/unit/Expressions/Literals/BooleanTest.php +++ b/tests/unit/Expressions/Literals/BooleanTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Literals; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Literals/FloatTest.php b/tests/unit/Expressions/Literals/FloatTest.php index d8163ca6..b1ec48e0 100644 --- a/tests/unit/Expressions/Literals/FloatTest.php +++ b/tests/unit/Expressions/Literals/FloatTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Literals; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Literals/IntegerTest.php b/tests/unit/Expressions/Literals/IntegerTest.php index c1364cc2..46cf08c6 100644 --- a/tests/unit/Expressions/Literals/IntegerTest.php +++ b/tests/unit/Expressions/Literals/IntegerTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Literals; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Literals/ListTest.php b/tests/unit/Expressions/Literals/ListTest.php index 54802dc5..cff2f545 100644 --- a/tests/unit/Expressions/Literals/ListTest.php +++ b/tests/unit/Expressions/Literals/ListTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Literals; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Literals/LiteralTest.php b/tests/unit/Expressions/Literals/LiteralTest.php index 08bfd386..73072ab8 100644 --- a/tests/unit/Expressions/Literals/LiteralTest.php +++ b/tests/unit/Expressions/Literals/LiteralTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Literals; use Iterator; diff --git a/tests/unit/Expressions/Literals/MapTest.php b/tests/unit/Expressions/Literals/MapTest.php index bfee9778..3dc4f32a 100644 --- a/tests/unit/Expressions/Literals/MapTest.php +++ b/tests/unit/Expressions/Literals/MapTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Literals; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Literals/StringTest.php b/tests/unit/Expressions/Literals/StringTest.php index 35044717..a497f955 100644 --- a/tests/unit/Expressions/Literals/StringTest.php +++ b/tests/unit/Expressions/Literals/StringTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Literals; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Operators/AdditionTest.php b/tests/unit/Expressions/Operators/AdditionTest.php index 4cd9511a..3c05ebf8 100644 --- a/tests/unit/Expressions/Operators/AdditionTest.php +++ b/tests/unit/Expressions/Operators/AdditionTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; @@ -40,7 +41,7 @@ public function testToQuery(): void $this->assertEquals($addition, $newAddition->getLeft()); $this->assertEquals($addition, $newAddition->getRight()); - $newAddition = new Addition($addition, $addition, false); + $newAddition = new Addition($addition, $addition); $this->assertSame("(10 + 15.0) + (10 + 15.0)", $newAddition->toQuery()); diff --git a/tests/unit/Expressions/Operators/ConjunctionTest.php b/tests/unit/Expressions/Operators/ConjunctionTest.php index 69735479..8963e5ae 100644 --- a/tests/unit/Expressions/Operators/ConjunctionTest.php +++ b/tests/unit/Expressions/Operators/ConjunctionTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Operators/ContainsTest.php b/tests/unit/Expressions/Operators/ContainsTest.php index 0545c3c0..2d802a11 100644 --- a/tests/unit/Expressions/Operators/ContainsTest.php +++ b/tests/unit/Expressions/Operators/ContainsTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Operators/DisjunctionTest.php b/tests/unit/Expressions/Operators/DisjunctionTest.php index 45fdc5c5..feeaebc5 100644 --- a/tests/unit/Expressions/Operators/DisjunctionTest.php +++ b/tests/unit/Expressions/Operators/DisjunctionTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Operators/DivisionTest.php b/tests/unit/Expressions/Operators/DivisionTest.php index d7c3fa16..a7ea0f64 100644 --- a/tests/unit/Expressions/Operators/DivisionTest.php +++ b/tests/unit/Expressions/Operators/DivisionTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Operators/EndsWithTest.php b/tests/unit/Expressions/Operators/EndsWithTest.php index 41c5301a..76c1bbbc 100644 --- a/tests/unit/Expressions/Operators/EndsWithTest.php +++ b/tests/unit/Expressions/Operators/EndsWithTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Operators/EqualityTest.php b/tests/unit/Expressions/Operators/EqualityTest.php index 97d9447a..557ff226 100644 --- a/tests/unit/Expressions/Operators/EqualityTest.php +++ b/tests/unit/Expressions/Operators/EqualityTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; @@ -28,7 +29,7 @@ public function testToQuery(): void $equality = new Equality($equality, $equality); - $this->assertSame("(10 = 15) = (10 = 15)", $equality->toQuery()); + $this->assertSame("10 = 15 = 10 = 15", $equality->toQuery()); } public function testInstanceOfBooleanType(): void diff --git a/tests/unit/Expressions/Operators/ExclusiveDisjunctionTest.php b/tests/unit/Expressions/Operators/ExclusiveDisjunctionTest.php index 59bec7aa..69d1d2fa 100644 --- a/tests/unit/Expressions/Operators/ExclusiveDisjunctionTest.php +++ b/tests/unit/Expressions/Operators/ExclusiveDisjunctionTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Operators/ExponentiationTest.php b/tests/unit/Expressions/Operators/ExponentiationTest.php index 2c927d60..81d966df 100644 --- a/tests/unit/Expressions/Operators/ExponentiationTest.php +++ b/tests/unit/Expressions/Operators/ExponentiationTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Operators/GreaterThanOrEqualTest.php b/tests/unit/Expressions/Operators/GreaterThanOrEqualTest.php index e70405cf..c734fc66 100644 --- a/tests/unit/Expressions/Operators/GreaterThanOrEqualTest.php +++ b/tests/unit/Expressions/Operators/GreaterThanOrEqualTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; @@ -27,7 +28,7 @@ public function testToQuery(): void $greaterThanOrEqual = new GreaterThanOrEqual($greaterThanOrEqual, $greaterThanOrEqual); - $this->assertSame("(10 >= 15) >= (10 >= 15)", $greaterThanOrEqual->toQuery()); + $this->assertSame("10 >= 15 >= 10 >= 15", $greaterThanOrEqual->toQuery()); } public function testInstanceOfBooleanType(): void diff --git a/tests/unit/Expressions/Operators/GreaterThanTest.php b/tests/unit/Expressions/Operators/GreaterThanTest.php index 46d0cefc..e74956f0 100644 --- a/tests/unit/Expressions/Operators/GreaterThanTest.php +++ b/tests/unit/Expressions/Operators/GreaterThanTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; @@ -25,9 +26,20 @@ public function testToQuery(): void $this->assertSame("10 > 15", $greaterThan->toQuery()); - $greaterThan = new GreaterThan($greaterThan, $greaterThan, false); + $greaterThan = new GreaterThan($greaterThan, $greaterThan); + + $this->assertSame("10 > 15 > 10 > 15", $greaterThan->toQuery()); + } + + public function testChainedComparisons(): void + { + $a = new Integer(10); + $b = new Integer(5); + $c = new Integer(1); + + $expr = $a->gt($b)->gt($c); - $this->assertSame("(10 > 15) > (10 > 15)", $greaterThan->toQuery()); + $this->assertSame("10 > 5 > 1", $expr->toQuery()); } public function testInstanceOfBooleanType(): void diff --git a/tests/unit/Expressions/Operators/InTest.php b/tests/unit/Expressions/Operators/InTest.php index 2d077dbe..08827b46 100644 --- a/tests/unit/Expressions/Operators/InTest.php +++ b/tests/unit/Expressions/Operators/InTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Operators/InequalityTest.php b/tests/unit/Expressions/Operators/InequalityTest.php index 13f40969..75e7ff06 100644 --- a/tests/unit/Expressions/Operators/InequalityTest.php +++ b/tests/unit/Expressions/Operators/InequalityTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; @@ -28,7 +29,7 @@ public function testToQuery(): void $inequality = new Inequality($inequality, $inequality); - $this->assertSame("(v.a <> v.b) <> (v.a <> v.b)", $inequality->toQuery()); + $this->assertSame("v.a <> v.b <> v.a <> v.b", $inequality->toQuery()); } public function testInstanceOfBooleanType(): void diff --git a/tests/unit/Expressions/Operators/IsNotNullTest.php b/tests/unit/Expressions/Operators/IsNotNullTest.php index 5d1dfb42..ffbd86a3 100644 --- a/tests/unit/Expressions/Operators/IsNotNullTest.php +++ b/tests/unit/Expressions/Operators/IsNotNullTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; @@ -21,7 +22,7 @@ final class IsNotNullTest extends TestCase { public function testToQuery(): void { - $isNotNull = new IsNotNull(new Boolean(true), false); + $isNotNull = new IsNotNull(new Boolean(true)); $this->assertSame("true IS NOT NULL", $isNotNull->toQuery()); diff --git a/tests/unit/Expressions/Operators/IsNullTest.php b/tests/unit/Expressions/Operators/IsNullTest.php index e307f3e8..8d9de7aa 100644 --- a/tests/unit/Expressions/Operators/IsNullTest.php +++ b/tests/unit/Expressions/Operators/IsNullTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; @@ -21,7 +22,7 @@ final class IsNullTest extends TestCase { public function testToQuery(): void { - $isNull = new IsNull(new Boolean(true), false); + $isNull = new IsNull(new Boolean(true)); $this->assertSame("true IS NULL", $isNull->toQuery()); diff --git a/tests/unit/Expressions/Operators/LessThanOrEqualTest.php b/tests/unit/Expressions/Operators/LessThanOrEqualTest.php index e03e1a21..644a51e8 100644 --- a/tests/unit/Expressions/Operators/LessThanOrEqualTest.php +++ b/tests/unit/Expressions/Operators/LessThanOrEqualTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; @@ -27,7 +28,7 @@ public function testToQuery(): void $lessThanOrEqual = new LessThanOrEqual($lessThanOrEqual, $lessThanOrEqual, false); - $this->assertSame("(10 <= 15) <= (10 <= 15)", $lessThanOrEqual->toQuery()); + $this->assertSame("10 <= 15 <= 10 <= 15", $lessThanOrEqual->toQuery()); } public function testInstanceOfBooleanType(): void diff --git a/tests/unit/Expressions/Operators/LessThanTest.php b/tests/unit/Expressions/Operators/LessThanTest.php index 8d5ff5eb..3b132ee1 100644 --- a/tests/unit/Expressions/Operators/LessThanTest.php +++ b/tests/unit/Expressions/Operators/LessThanTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; @@ -25,9 +26,9 @@ public function testToQuery(): void $this->assertSame("10 < 15", $lessThan->toQuery()); - $lessThan = new LessThan($lessThan, $lessThan, false); + $lessThan = new LessThan($lessThan, $lessThan); - $this->assertSame("(10 < 15) < (10 < 15)", $lessThan->toQuery()); + $this->assertSame("10 < 15 < 10 < 15", $lessThan->toQuery()); } public function testInstanceOfBooleanType(): void diff --git a/tests/unit/Expressions/Operators/ModuloDivisionTest.php b/tests/unit/Expressions/Operators/ModuloDivisionTest.php index 900953ca..3541c001 100644 --- a/tests/unit/Expressions/Operators/ModuloDivisionTest.php +++ b/tests/unit/Expressions/Operators/ModuloDivisionTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Operators/MultiplicationTest.php b/tests/unit/Expressions/Operators/MultiplicationTest.php index 7051fed2..b21faa9c 100644 --- a/tests/unit/Expressions/Operators/MultiplicationTest.php +++ b/tests/unit/Expressions/Operators/MultiplicationTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; @@ -34,14 +35,14 @@ public function testToQuery(): void public function testInstanceOfFloatType(): void { - $multiplication = new Multiplication(new Float_(10.0), new Float_(15.0), false); + $multiplication = new Multiplication(new Float_(10.0), new Float_(15.0)); $this->assertInstanceOf(FloatType::class, $multiplication); } public function testInstanceOfIntegerType(): void { - $multiplication = new Multiplication(new Integer(10), new Integer(15), false); + $multiplication = new Multiplication(new Integer(10), new Integer(15)); $this->assertInstanceOf(IntegerType::class, $multiplication); } diff --git a/tests/unit/Expressions/Operators/NegationTest.php b/tests/unit/Expressions/Operators/NegationTest.php index 84c8e408..32933c3e 100644 --- a/tests/unit/Expressions/Operators/NegationTest.php +++ b/tests/unit/Expressions/Operators/NegationTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Operators/PrecedenceTest.php b/tests/unit/Expressions/Operators/PrecedenceTest.php index 47e53c70..77f18525 100644 --- a/tests/unit/Expressions/Operators/PrecedenceTest.php +++ b/tests/unit/Expressions/Operators/PrecedenceTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; @@ -106,7 +107,7 @@ public function testComparisonWithAdditive(): void $this->assertSame('10 + 5 > 10 - 5', $expr->toQuery()); $expr = new Equality(new Inequality($num1, $num2), new Boolean(true)); - $this->assertSame('(10 <> 5) = true', $expr->toQuery()); + $this->assertSame('10 <> 5 = true', $expr->toQuery()); } public function testAdditiveWithMultiplicative(): void @@ -380,7 +381,7 @@ public function testMixedUnaryBinaryNesting(): void new LessThan($num, $num), $num ); - $this->assertSame('(3.0 < 3.0) < 3.0', $expr->toQuery()); + $this->assertSame('3.0 < 3.0 < 3.0', $expr->toQuery()); $expr = new Multiplication( new UnaryMinus(new Exponentiation($num, $num)), @@ -452,10 +453,10 @@ public function testAllSamePrecedenceCombinations(): void $this->assertSame('NOT (NOT true)', $expr->toQuery()); $expr = new Equality(new LessThan($num, $num), $true); - $this->assertSame('(7.0 < 7.0) = true', $expr->toQuery()); + $this->assertSame('7.0 < 7.0 = true', $expr->toQuery()); $expr = new LessThanOrEqual(new GreaterThanOrEqual($num, $num), $num); - $this->assertSame('(7.0 >= 7.0) <= 7.0', $expr->toQuery()); + $this->assertSame('7.0 >= 7.0 <= 7.0', $expr->toQuery()); $expr = new Addition(new Subtraction($num, $num), $num); $this->assertSame('(7.0 - 7.0) + 7.0', $expr->toQuery()); @@ -478,4 +479,68 @@ public function testAllSamePrecedenceCombinations(): void $expr = new Equality(new Contains($var, $var), new StartsWith($var, $var)); $this->assertSame('y CONTAINS y = y STARTS WITH y', $expr->toQuery()); } + + public function testChainedComparison(): void + { + $a = new Integer(10); + $b = new Integer(5); + $c = new Integer(1); + + $expr = new GreaterThan(new GreaterThan($a, $b), $c); + $this->assertSame("10 > 5 > 1", $expr->toQuery()); + } + + public function testChainedComparisonRhs(): void + { + $a = new Integer(10); + $b = new Integer(5); + $c = new Integer(1); + + $expr = new GreaterThan($a, new GreaterThan($b, $c)); + $this->assertSame("10 > 5 > 1", $expr->toQuery()); + } + + public function testChainedComparisonRhsCheck(): void + { + $a = new Integer(10); + $b = new Integer(5); + $c = new Integer(1); + $d = new Integer(0); + + $expr = new GreaterThan($a, new GreaterThan($b, new GreaterThan($c, $d))); + $this->assertSame("10 > 5 > 1 > 0", $expr->toQuery()); + } + + public function testChainedMixedComparisons(): void + { + $a = new Integer(10); + $b = new Integer(5); + $c = new Integer(5); + + $expr = new GreaterThanOrEqual(new GreaterThan($a, $b), $c); + $this->assertSame("10 > 5 >= 5", $expr->toQuery()); + } + + public function testChainedInequality(): void + { + $a = new Integer(10); + $b = new Integer(5); + $c = new Integer(10); + + $expr = new Inequality(new Inequality($a, $b), $c); + $this->assertSame("10 <> 5 <> 10", $expr->toQuery()); + } + + public function testChainedEquality(): void + { + $a = new Integer(1); + $b = new Integer(1); + $c = new Integer(1); + + $expr = new Equality(new Equality($a, $b), $c); + $this->assertSame("1 = 1 = 1", $expr->toQuery()); + + $expr = new Equality($a, new Equality($b, $c)); + $this->assertSame("1 = 1 = 1", $expr->toQuery()); + } } diff --git a/tests/unit/Expressions/Operators/RegexTest.php b/tests/unit/Expressions/Operators/RegexTest.php index 122e08b0..fbaa9494 100644 --- a/tests/unit/Expressions/Operators/RegexTest.php +++ b/tests/unit/Expressions/Operators/RegexTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Operators/StartsWithTest.php b/tests/unit/Expressions/Operators/StartsWithTest.php index 4e02b91a..57f23c1a 100644 --- a/tests/unit/Expressions/Operators/StartsWithTest.php +++ b/tests/unit/Expressions/Operators/StartsWithTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Operators/SubtractionTest.php b/tests/unit/Expressions/Operators/SubtractionTest.php index 0655dfdc..aa055b34 100644 --- a/tests/unit/Expressions/Operators/SubtractionTest.php +++ b/tests/unit/Expressions/Operators/SubtractionTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Operators/UnaryMinusTest.php b/tests/unit/Expressions/Operators/UnaryMinusTest.php index c5541bfd..97c9eeb9 100644 --- a/tests/unit/Expressions/Operators/UnaryMinusTest.php +++ b/tests/unit/Expressions/Operators/UnaryMinusTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Operators; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/ParameterTest.php b/tests/unit/Expressions/ParameterTest.php index dbbb341a..79e2958c 100644 --- a/tests/unit/Expressions/ParameterTest.php +++ b/tests/unit/Expressions/ParameterTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions; use InvalidArgumentException; diff --git a/tests/unit/Expressions/Procedures/AllTest.php b/tests/unit/Expressions/Procedures/AllTest.php index f16826e5..a2b2800c 100644 --- a/tests/unit/Expressions/Procedures/AllTest.php +++ b/tests/unit/Expressions/Procedures/AllTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Procedures; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Procedures/AnyTest.php b/tests/unit/Expressions/Procedures/AnyTest.php index 814f8ac1..12c7c71b 100644 --- a/tests/unit/Expressions/Procedures/AnyTest.php +++ b/tests/unit/Expressions/Procedures/AnyTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Procedures; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Procedures/DateTest.php b/tests/unit/Expressions/Procedures/DateTest.php index e999b4c4..12170249 100644 --- a/tests/unit/Expressions/Procedures/DateTest.php +++ b/tests/unit/Expressions/Procedures/DateTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Procedures; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Procedures/DateTimeTest.php b/tests/unit/Expressions/Procedures/DateTimeTest.php index ff55e6bc..c9ecf4ac 100644 --- a/tests/unit/Expressions/Procedures/DateTimeTest.php +++ b/tests/unit/Expressions/Procedures/DateTimeTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Procedures; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Procedures/ExistsTest.php b/tests/unit/Expressions/Procedures/ExistsTest.php index 819e9169..e51e8744 100644 --- a/tests/unit/Expressions/Procedures/ExistsTest.php +++ b/tests/unit/Expressions/Procedures/ExistsTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Procedures; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Procedures/IsEmptyTest.php b/tests/unit/Expressions/Procedures/IsEmptyTest.php index 5a68e26a..204e5235 100644 --- a/tests/unit/Expressions/Procedures/IsEmptyTest.php +++ b/tests/unit/Expressions/Procedures/IsEmptyTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Procedures; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Procedures/LocalDateTimeTest.php b/tests/unit/Expressions/Procedures/LocalDateTimeTest.php index 2919960e..1955063b 100644 --- a/tests/unit/Expressions/Procedures/LocalDateTimeTest.php +++ b/tests/unit/Expressions/Procedures/LocalDateTimeTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Procedures; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Procedures/LocalTimeTest.php b/tests/unit/Expressions/Procedures/LocalTimeTest.php index 18949207..0f07cbbb 100644 --- a/tests/unit/Expressions/Procedures/LocalTimeTest.php +++ b/tests/unit/Expressions/Procedures/LocalTimeTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Procedures; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Procedures/NoneTest.php b/tests/unit/Expressions/Procedures/NoneTest.php index 2d320132..8bafa284 100644 --- a/tests/unit/Expressions/Procedures/NoneTest.php +++ b/tests/unit/Expressions/Procedures/NoneTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Procedures; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Procedures/PointTest.php b/tests/unit/Expressions/Procedures/PointTest.php index 52cbb594..e1f118d2 100644 --- a/tests/unit/Expressions/Procedures/PointTest.php +++ b/tests/unit/Expressions/Procedures/PointTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Procedures; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Procedures/ProcedureTest.php b/tests/unit/Expressions/Procedures/ProcedureTest.php index efb44554..252fa634 100644 --- a/tests/unit/Expressions/Procedures/ProcedureTest.php +++ b/tests/unit/Expressions/Procedures/ProcedureTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Procedures; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Procedures/RawTest.php b/tests/unit/Expressions/Procedures/RawTest.php index 34aa0947..fcc5b786 100644 --- a/tests/unit/Expressions/Procedures/RawTest.php +++ b/tests/unit/Expressions/Procedures/RawTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Procedures; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Procedures/SingleTest.php b/tests/unit/Expressions/Procedures/SingleTest.php index cdda8057..03659549 100644 --- a/tests/unit/Expressions/Procedures/SingleTest.php +++ b/tests/unit/Expressions/Procedures/SingleTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Procedures; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/Procedures/TimeTest.php b/tests/unit/Expressions/Procedures/TimeTest.php index 786b7469..bf64b3bc 100644 --- a/tests/unit/Expressions/Procedures/TimeTest.php +++ b/tests/unit/Expressions/Procedures/TimeTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions\Procedures; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/PropertyTest.php b/tests/unit/Expressions/PropertyTest.php index bc418a87..5ab0c48f 100644 --- a/tests/unit/Expressions/PropertyTest.php +++ b/tests/unit/Expressions/PropertyTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/RawExpressionTest.php b/tests/unit/Expressions/RawExpressionTest.php index 813df55e..93449b4f 100644 --- a/tests/unit/Expressions/RawExpressionTest.php +++ b/tests/unit/Expressions/RawExpressionTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Expressions/VariableTest.php b/tests/unit/Expressions/VariableTest.php index dea06368..68340204 100644 --- a/tests/unit/Expressions/VariableTest.php +++ b/tests/unit/Expressions/VariableTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Expressions; use InvalidArgumentException; diff --git a/tests/unit/FunctionsTest.php b/tests/unit/FunctionsTest.php index 849b4669..d0ea56ff 100644 --- a/tests/unit/FunctionsTest.php +++ b/tests/unit/FunctionsTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Patterns/NodeTest.php b/tests/unit/Patterns/NodeTest.php index 8f64e3f0..f9b65486 100644 --- a/tests/unit/Patterns/NodeTest.php +++ b/tests/unit/Patterns/NodeTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Patterns; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Patterns/PathTest.php b/tests/unit/Patterns/PathTest.php index 0a5d59a1..dfea440b 100644 --- a/tests/unit/Patterns/PathTest.php +++ b/tests/unit/Patterns/PathTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Patterns; use PHPUnit\Framework\TestCase; @@ -109,6 +110,6 @@ public function testPathCanBeTreatedAsBoolean(): void $pathA = new Path([new Node(), new Node()], [new Relationship(Direction::UNI)]); $pathB = new Path([new Node(), new Node()], [new Relationship(Direction::RIGHT)]); - $this->assertSame("()--() AND ()-->()", $pathA->and($pathB, false)->toQuery()); + $this->assertSame("()--() AND ()-->()", $pathA->and($pathB)->toQuery()); } } diff --git a/tests/unit/Patterns/RelationshipTest.php b/tests/unit/Patterns/RelationshipTest.php index 75349e61..e015a5cf 100644 --- a/tests/unit/Patterns/RelationshipTest.php +++ b/tests/unit/Patterns/RelationshipTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Patterns; use DomainException; diff --git a/tests/unit/QueryCallProcedureTest.php b/tests/unit/QueryCallProcedureTest.php index df8c2f9d..7a3fdc48 100644 --- a/tests/unit/QueryCallProcedureTest.php +++ b/tests/unit/QueryCallProcedureTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/QueryCallTest.php b/tests/unit/QueryCallTest.php index c73f8bab..18a76d48 100644 --- a/tests/unit/QueryCallTest.php +++ b/tests/unit/QueryCallTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; @@ -22,8 +23,7 @@ final class QueryCallTest extends TestCase { public function testWithCallable(): void { - $query = Query::new()->call(static function (Query $query): void - { + $query = Query::new()->call(static function (Query $query): void { $query->match(Query::node('x')); }); @@ -35,8 +35,7 @@ public function testWithCallableOnlyAcceptsQuery(): void $this->expectException(TypeError::class); // @phpstan-ignore-next-line - Query::new()->call(static function (int $query): void - { + Query::new()->call(static function (int $query): void { }); } @@ -63,43 +62,37 @@ public function testWithEmptyQueryAndVariables(): void public function testWithVariables(): void { - $query = Query::new()->call(static function (Query $query): void - { + $query = Query::new()->call(static function (Query $query): void { $query->match(Query::node('x')); }, Query::variable('x')); $this->assertSame('CALL { WITH x MATCH (:x) }', $query->toQuery()); - $query = Query::new()->call(static function (Query $query): void - { + $query = Query::new()->call(static function (Query $query): void { $query->match(Query::node('x')); }, [Query::variable('x')]); $this->assertSame('CALL { WITH x MATCH (:x) }', $query->toQuery()); - $query = Query::new()->call(static function (Query $query): void - { + $query = Query::new()->call(static function (Query $query): void { $query->match(Query::node('x')); }, [Query::variable('x'), Query::variable('y')]); $this->assertSame('CALL { WITH x, y MATCH (:x) }', $query->toQuery()); - $query = Query::new()->call(static function (Query $query): void - { + $query = Query::new()->call(static function (Query $query): void { $query->match(Query::node('x')); }, 'x'); $this->assertSame('CALL { WITH x MATCH (:x) }', $query->toQuery()); - $query = Query::new()->call(static function (Query $query): void - { + $query = Query::new()->call(static function (Query $query): void { $query->match(Query::node('x')); }, ['x', 'y']); $this->assertSame('CALL { WITH x, y MATCH (:x) }', $query->toQuery()); - $query = Query::new()->call(static function (Query $query): void - { + $query = Query::new()->call(static function (Query $query): void { $query->match(Query::node('x')); }, Query::node()); diff --git a/tests/unit/QueryCreateTest.php b/tests/unit/QueryCreateTest.php index b1cf08ac..2eccd273 100644 --- a/tests/unit/QueryCreateTest.php +++ b/tests/unit/QueryCreateTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/QueryDeleteTest.php b/tests/unit/QueryDeleteTest.php index 003f067a..06932a35 100644 --- a/tests/unit/QueryDeleteTest.php +++ b/tests/unit/QueryDeleteTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/QueryLimitTest.php b/tests/unit/QueryLimitTest.php index ad94bdf0..65dd2c20 100644 --- a/tests/unit/QueryLimitTest.php +++ b/tests/unit/QueryLimitTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/QueryMatchTest.php b/tests/unit/QueryMatchTest.php index b2957c27..b6ecd906 100644 --- a/tests/unit/QueryMatchTest.php +++ b/tests/unit/QueryMatchTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/QueryMergeTest.php b/tests/unit/QueryMergeTest.php index 3da7eaed..39731a98 100644 --- a/tests/unit/QueryMergeTest.php +++ b/tests/unit/QueryMergeTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/QueryOptionalMatchTest.php b/tests/unit/QueryOptionalMatchTest.php index 3b0e817f..feb40318 100644 --- a/tests/unit/QueryOptionalMatchTest.php +++ b/tests/unit/QueryOptionalMatchTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/QueryOrderByTest.php b/tests/unit/QueryOrderByTest.php index 9c1312de..0e0781dc 100644 --- a/tests/unit/QueryOrderByTest.php +++ b/tests/unit/QueryOrderByTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/QueryRawTest.php b/tests/unit/QueryRawTest.php index 7023e66a..b9a50a16 100644 --- a/tests/unit/QueryRawTest.php +++ b/tests/unit/QueryRawTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/QueryRemoveTest.php b/tests/unit/QueryRemoveTest.php index 71e56fdb..42b32b83 100644 --- a/tests/unit/QueryRemoveTest.php +++ b/tests/unit/QueryRemoveTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/QueryReturningTest.php b/tests/unit/QueryReturningTest.php index e7ff15f1..e2196278 100644 --- a/tests/unit/QueryReturningTest.php +++ b/tests/unit/QueryReturningTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/QuerySetTest.php b/tests/unit/QuerySetTest.php index fd704c9d..db0517b1 100644 --- a/tests/unit/QuerySetTest.php +++ b/tests/unit/QuerySetTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/QuerySkipTest.php b/tests/unit/QuerySkipTest.php index c0d86767..3a8041f6 100644 --- a/tests/unit/QuerySkipTest.php +++ b/tests/unit/QuerySkipTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/QueryTest.php b/tests/unit/QueryTest.php index 215373db..785b9fb5 100644 --- a/tests/unit/QueryTest.php +++ b/tests/unit/QueryTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use Iterator; @@ -303,7 +304,7 @@ public function testBuild(): void $pathMock = new Path([$nodeMock, (new Node)->withVariable('b')], [new Relationship(Direction::RIGHT)]); $numeralMock = new Integer(12); - $booleanMock = new GreaterThan($variableMock, new Variable('b'), false); + $booleanMock = new GreaterThan($variableMock, new Variable('b')); $propertyMock = new Property($variableMock, 'b'); $query = new Query(); diff --git a/tests/unit/QueryUnionTest.php b/tests/unit/QueryUnionTest.php index 5af04a31..b808a273 100644 --- a/tests/unit/QueryUnionTest.php +++ b/tests/unit/QueryUnionTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; @@ -51,8 +52,7 @@ public function testUnionDecorator(): void $query = Query::new()->match($nodeX)->returning($nodeX->getVariable()); - $query = $query->union(static function (Query $query): void - { + $query = $query->union(static function (Query $query): void { $nodeY = Query::node('Y')->withVariable('y'); $query->match($nodeY)->returning($nodeY->getVariable()); }); @@ -66,8 +66,7 @@ public function testUnionDecoratorAll(): void $query = Query::new()->match($nodeX)->returning($nodeX->getVariable()); - $query = $query->union(static function (Query $query): void - { + $query = $query->union(static function (Query $query): void { $nodeY = Query::node('Y')->withVariable('y'); $query->match($nodeY)->returning($nodeY->getVariable()); }, true); diff --git a/tests/unit/QueryWhereTest.php b/tests/unit/QueryWhereTest.php index 3affb378..5ec5969f 100644 --- a/tests/unit/QueryWhereTest.php +++ b/tests/unit/QueryWhereTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use InvalidArgumentException; diff --git a/tests/unit/QueryWithTest.php b/tests/unit/QueryWithTest.php index 158d9e27..496fb72a 100644 --- a/tests/unit/QueryWithTest.php +++ b/tests/unit/QueryWithTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Syntax/AliasTest.php b/tests/unit/Syntax/AliasTest.php index 388934f5..61783832 100644 --- a/tests/unit/Syntax/AliasTest.php +++ b/tests/unit/Syntax/AliasTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Syntax; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Syntax/PropertyReplacementTest.php b/tests/unit/Syntax/PropertyReplacementTest.php index 4e18826a..8316f715 100644 --- a/tests/unit/Syntax/PropertyReplacementTest.php +++ b/tests/unit/Syntax/PropertyReplacementTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Syntax; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Traits/PatternTraits/PatternTraitTest.php b/tests/unit/Traits/PatternTraits/PatternTraitTest.php index 3e767f8a..5bc6ae46 100644 --- a/tests/unit/Traits/PatternTraits/PatternTraitTest.php +++ b/tests/unit/Traits/PatternTraits/PatternTraitTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Traits\PatternTraits; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Traits/PatternTraits/PropertyPatternTraitTest.php b/tests/unit/Traits/PatternTraits/PropertyPatternTraitTest.php index efc7eba4..e7777a5a 100644 --- a/tests/unit/Traits/PatternTraits/PropertyPatternTraitTest.php +++ b/tests/unit/Traits/PatternTraits/PropertyPatternTraitTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Traits\PatternTraits; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Traits/TypeTraits/AnyTypeTraitTest.php b/tests/unit/Traits/TypeTraits/AnyTypeTraitTest.php index 95acf59b..56f9f670 100644 --- a/tests/unit/Traits/TypeTraits/AnyTypeTraitTest.php +++ b/tests/unit/Traits/TypeTraits/AnyTypeTraitTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Traits\TypeTraits; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Traits/TypeTraits/CompositeTypeTraits/ListTypeTraitTest.php b/tests/unit/Traits/TypeTraits/CompositeTypeTraits/ListTypeTraitTest.php index 00ac4bc2..331d9880 100644 --- a/tests/unit/Traits/TypeTraits/CompositeTypeTraits/ListTypeTraitTest.php +++ b/tests/unit/Traits/TypeTraits/CompositeTypeTraits/ListTypeTraitTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Traits\TypeTraits\CompositeTypeTraits; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Traits/TypeTraits/MethodTraits/PropertyMethodTraitTest.php b/tests/unit/Traits/TypeTraits/MethodTraits/PropertyMethodTraitTest.php index 2f83ebf0..533eee9d 100644 --- a/tests/unit/Traits/TypeTraits/MethodTraits/PropertyMethodTraitTest.php +++ b/tests/unit/Traits/TypeTraits/MethodTraits/PropertyMethodTraitTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Traits\TypeTraits\MethodTraits; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Traits/TypeTraits/PropertyTypeTraits/BooleanTypeTraitTest.php b/tests/unit/Traits/TypeTraits/PropertyTypeTraits/BooleanTypeTraitTest.php index 18a75fd4..9398cb5c 100644 --- a/tests/unit/Traits/TypeTraits/PropertyTypeTraits/BooleanTypeTraitTest.php +++ b/tests/unit/Traits/TypeTraits/PropertyTypeTraits/BooleanTypeTraitTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Traits\TypeTraits\PropertyTypeTraits; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Traits/TypeTraits/PropertyTypeTraits/NumeralTypeTraitTest.php b/tests/unit/Traits/TypeTraits/PropertyTypeTraits/NumeralTypeTraitTest.php index acc4c0e8..de0f2175 100644 --- a/tests/unit/Traits/TypeTraits/PropertyTypeTraits/NumeralTypeTraitTest.php +++ b/tests/unit/Traits/TypeTraits/PropertyTypeTraits/NumeralTypeTraitTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Traits\TypeTraits\PropertyTypeTraits; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Traits/TypeTraits/PropertyTypeTraits/PropertyTypeTraitTest.php b/tests/unit/Traits/TypeTraits/PropertyTypeTraits/PropertyTypeTraitTest.php index 6ed3d145..52565216 100644 --- a/tests/unit/Traits/TypeTraits/PropertyTypeTraits/PropertyTypeTraitTest.php +++ b/tests/unit/Traits/TypeTraits/PropertyTypeTraits/PropertyTypeTraitTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Traits\TypeTraits\PropertyTypeTraits; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Traits/TypeTraits/PropertyTypeTraits/StringTypeTraitTest.php b/tests/unit/Traits/TypeTraits/PropertyTypeTraits/StringTypeTraitTest.php index 1438bfb8..d5877f87 100644 --- a/tests/unit/Traits/TypeTraits/PropertyTypeTraits/StringTypeTraitTest.php +++ b/tests/unit/Traits/TypeTraits/PropertyTypeTraits/StringTypeTraitTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Traits\TypeTraits\PropertyTypeTraits; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Utils/CastUtilsTest.php b/tests/unit/Utils/CastUtilsTest.php index 5b687c2b..41a5ce40 100644 --- a/tests/unit/Utils/CastUtilsTest.php +++ b/tests/unit/Utils/CastUtilsTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Utils; use PHPUnit\Framework\TestCase; diff --git a/tests/unit/Utils/NameUtilsTest.php b/tests/unit/Utils/NameUtilsTest.php index 7433cdc0..c5e8cc5c 100644 --- a/tests/unit/Utils/NameUtilsTest.php +++ b/tests/unit/Utils/NameUtilsTest.php @@ -7,6 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ + namespace WikibaseSolutions\CypherDSL\Tests\Unit\Utils; use InvalidArgumentException;