stable

Clone or download

Read-only

Fix empty string comparisons

This is a part of story #8859 TQL search on date & numeric fields string = "" Artifacts where string is empty string != "" Artifacts where string is not empty integer = "" Artifacts where integer is empty integer != "" Artifacts where integer is not empty integer < "" Impossibru (same for other operators) float = "" Artifacts where float is empty float != "" Artifacts where float is not empty float < "" Impossibru (same for other operators) date = "" Artifacts where date is empty time = "" Artifacts where time is empty date/time != "" will be done in another changeset date < "" will be done in another changeset Change-Id: I42434a6ba3cfbc6ec1baffa86ea7be3019ef67aa

Modified Files

Name
M plugins/tracker/include/Tracker/Report/Query/Advanced/Grammar/Comparison.php +1 −1 Go to diff View file
A plugins/tracker/include/Tracker/Report/Query/Advanced/Grammar/NoVisitorParameters.php +24 −0 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/DateFieldChecker.php +6 −1 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/DateTimeFieldChecker.php +6 −1 Go to diff View file
A plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/EmptyStringAllowed.php +28 −0 Go to diff View file
A plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/EmptyStringChecker.php +29 −0 Go to diff View file
A plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/EmptyStringForbidden.php +28 −0 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/EqualComparisonVisitor.php +2 −2 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/FloatFieldChecker.php +15 −1 Go to diff View file
A plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/FloatToEmptyStringComparisonException.php +80 −0 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/GreaterThanComparisonVisitor.php +2 −2 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/GreaterThanOrEqualComparisonVisitor.php +2 −2 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/IntegerFieldChecker.php +15 −1 Go to diff View file
A plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/IntegerToEmptyStringComparisonException.php +80 −0 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/LesserThanComparisonVisitor.php +2 −2 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/LesserThanOrEqualComparisonVisitor.php +2 −2 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/InvalidFields/NotEqualComparisonVisitor.php +2 −2 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/QueryBuilder/EqualComparison/ForDate.php +1 −1 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/QueryBuilder/EqualComparison/ForDateTime.php +1 −1 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/QueryBuilder/EqualComparison/ForFloat.php +1 −1 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/QueryBuilder/EqualComparison/ForInteger.php +1 −1 Go to diff View file
M plugins/tracker/include/Tracker/Report/Query/Advanced/QueryBuilder/EqualComparison/ForText.php +7 −1 Go to diff View file
M plugins/tracker/include/autoload.php +8 −2 Go to diff View file
M plugins/tracker/site-content/fr_FR/LC_MESSAGES/tuleap-tracker.po +78 −2 Go to diff View file
M plugins/tracker/site-content/tuleap-tracker.pot +56 −0 Go to diff View file
A plugins/tracker/tests/Tracker/Report/Query/Advanced/InvalidFields/DateFieldCheckerTest.php +75 −0 Go to diff View file
A plugins/tracker/tests/Tracker/Report/Query/Advanced/InvalidFields/DateTimeFieldCheckerTest.php +83 −0 Go to diff View file
M plugins/tracker/tests/builders/aField.php +20 −6 Go to diff View file