Comparing yearMonthDuration to dayTimeDuration and vice versa is failing (eq operator)
mstevan opened this issue · 3 comments
@mstevan
test-set: op/duration-equal.xml
test-cases: all that fail are
@team
Comparing yearMonthDuration to dayTimeDuration and vice versa is failing (eq operator)
Input:
yearMonthDuration("P0M") eq dayTimeDuration("PT0S")
Output:
Code: [XPTY0004] (this code can be looked up in the documentation and specifications).
Location information: file:/Users/mstevan/Documents/:LINE:1:COLUMN:0:
"yearMonthDuration": invalid type: can not compare for equality to type "dayTimeDuration"
Expected output:
true
This is fixed.
All tests are passing, however I think that implementation may have broken what used to work before.
@ghislainfourny Please check ne operator for comparing duration with duration, it is causing issues:
Input:
duration("P1Y") ne duration("P1Y")
Output:
org.rumbledb.exceptions.UnexpectedTypeException: There was an error.
Code: [XPTY0004] (this code can be looked up in the documentation and specifications).
Location information: file:/Users/mstevan/Documents/rumble-test-suite/:LINE:1:COLUMN:0:
"ne": operation not possible with parameters of type "duration" and "duration"
Expected output:
false
Fully fixed now, all tests are passing and no new crashes caused by fix