-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
Cleanup Series arithmetic tests #18974
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
Conversation
Travis error in TestTSPlot.test_time looks unrelated. |
expected = TimedeltaIndex(np.arange(5, dtype='int64') ** 2) | ||
tm.assert_index_equal(result, expected) | ||
|
||
# FIXME: These ops should return Series, NOT indexes |
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.
TODO
data = [[1, 2, 3], | ||
[1.1, 2.2, 3.3], | ||
[pd.Timestamp('2011-01-01'), pd.Timestamp('2011-01-02'), | ||
pd.NaT], |
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.
paramaterize
|
||
def test_invalid_add_sub(self): | ||
# invalid ops | ||
obj_series = tm.makeObjectSeries() |
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.
can you add a comment
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.
Sure. Now that I actually look at tm.makeObjectSeries()
I'm surprised that it gives a Series[datetime64] with what looks like random strings for its Index. I'll move this down into TestDatetimeSeriesArithmetic
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.
Incidentally, this is one of the cases that DatetimeIndex.__add__
/__sub__
messes up.
Codecov Report
@@ Coverage Diff @@
## master #18974 +/- ##
==========================================
+ Coverage 91.58% 91.58% +<.01%
==========================================
Files 150 150
Lines 48967 48939 -28
==========================================
- Hits 44846 44823 -23
+ Misses 4121 4116 -5
Continue to review full report at Codecov.
|
…eanup_series_tests
Test error still looks unrelated and this is bound to cause merge headaches for other higher-priority PRs. Closing for now, will circle back eventually. |
Also a few for TimedeltaIndex. One of the TimedeltaIndex tests specifically tests a behavior I think is wrong, #18963. Actually fixing that bug is separate.
Actual content of tests is unchanged.