-
Notifications
You must be signed in to change notification settings - Fork 5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Datetime extraction and arithmetics for text column in mongo #26339
Conversation
:breakout [[:expression "expr"]]}}]] | ||
(testing (format "%s %s function works as expected on %s column for driver %s" op unit col-type driver/*driver*) | ||
(is (= (set expected) (set (qp.datetime-test/test-datetime-math query)))))))) | ||
(doseq [[col-type field-id] [[:datetime (mt/id :times :dt)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
move [col-type field-id]
from let
into doseq
so we could run on multiple col-types
@@ -92,42 +92,25 @@ | |||
|
|||
(deftest extraction-function-tests | |||
(mt/dataset times-mixed | |||
;; need to have seperate tests for mongo because it doesn't have supports for casting yet | |||
(mt/test-drivers (disj (mt/normal-drivers-with-feature :temporal-extract) :mongo) | |||
(mt/test-drivers (mt/normal-drivers-with-feature :temporal-extract) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Before this, we had duplicated testing for mongo because they don't have supports for casting, but now those test will be merged together.
So even though we're deleting code, we actually running more tests here.
Codecov ReportBase: 64.29% // Head: 64.29% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## master #26339 +/- ##
=======================================
Coverage 64.29% 64.29%
=======================================
Files 3149 3149
Lines 92258 92259 +1
Branches 11704 11702 -2
=======================================
+ Hits 59316 59318 +2
- Misses 28254 28255 +1
+ Partials 4688 4686 -2
Flags with carried forward coverage won't be shown. Click here to find out more.
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cool, works for me
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Datetime extraction and arithmetics were implemented in #25277 and #25414 respectively.
But at the time, Mongo hadn't supported casting a
text
column todatetime
so some tests were skipped for Mongo.Now we added it in #22313, we should run those tests for Mongo