Separate out arithmetic tests for datetimelike indexes
State: closed

As discussed... somewhere.  I'll find the reference tomorrow.

This is about as close as I could get to pure cut/paste.  There are a few notes to sprinkle in about things to clean up in a follow-up.

In a couple places this wraps some string literals to make folding easier.

Labels:
name: Testing
description: pandas testing functions or related to the test suite
name: Datetime
description: Datetime data dtype
name: Timedelta
description: Timedelta data type
name: Period
description: Period data type

Comments:
Looking at tests.indexes: 3824 under PR, 3829 under master.  Removal of duplicate Julian tests accounts for the difference
From Travis log:

```
=================================== FAILURES ===================================
________________ TestClipboard.test_round_trip_valid_encodings _________________
self = <pandas.tests.io.test_clipboard.TestClipboard object at 0x7f8377152438>
    def test_round_trip_valid_encodings(self):
        for enc in ['UTF-8', 'utf-8', 'utf8']:
            for dt in self.data_types:
>               self.check_round_trip_frame(dt, encoding=enc)
pandas/tests/io/test_clipboard.py:136: 
[...]
>       raise AssertionError(msg)
E       AssertionError: DataFrame are different
E       
E       DataFrame shape mismatch
E       [left]:  (5, 3)
E       [right]: (2, 2)
[...]
pandas/util/testing.py:1089: AssertionError
============================ 15513 tests deselected ============================
 1 failed, 518 passed, 22 skipped, 15513 deselected, 1 xfailed in 164.49 seconds 
sys:1: ResourceWarning: unclosed <socket.socket fd=4, family=AddressFamily.AF_INET, type=2050, proto=0, laddr=('0.0.0.0', 0)>
[...]
..ValueError: Buffer dtype mismatch, expected 'Python object' but got 'long'
Exception ignored in: 'pandas._libs.lib.is_bool_array'
ValueError: Buffer dtype mismatch, expected 'Python object' but got 'long'
.................ValueError: Buffer dtype mismatch, expected 'Python object' but got 'long'
Exception ignored in: 'pandas._libs.lib.is_bool_array'
ValueError: Buffer dtype mismatch, expected 'Python object' but got 'long'
.ValueError: Buffer dtype mismatch, expected 'Python object' but got 'long'
Exception ignored in: 'pandas._libs.lib.is_bool_array'
ValueError: Buffer dtype mismatch, expected 'Python object' but got 'long'
```

No idea if the buffer mismatches are related to the TestClipboard error.  The latter has shown up a handful of times and usually goes away with re-running the CI.
# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=h1) Report
> Merging [#18049](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/c65a0f554b0381ac3f50762050a56bcff188ffa1?src=pr&el=desc) will **decrease** coverage by `0.01%`.
> The diff coverage is `n/a`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/18049/graphs/tree.svg?width=650&src=pr&token=eZ4WkYLtcO&height=150)](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=tree)

```diff
@@            Coverage Diff             @@
##           master   #18049      +/-   ##
==========================================
- Coverage   91.24%   91.23%   -0.02%     
==========================================
  Files         163      163              
  Lines       50114    50114              
==========================================
- Hits        45729    45720       -9     
- Misses       4385     4394       +9
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `89.04% <ø> (ø)` | :arrow_up: |
| #single | `40.24% <ø> (-0.06%)` | :arrow_down: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/io/gbq.py](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=tree#diff-cGFuZGFzL2lvL2dicS5weQ==) | `25% <0%> (-58.34%)` | :arrow_down: |
| [pandas/core/frame.py](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvZnJhbWUucHk=) | `97.75% <0%> (-0.1%)` | :arrow_down: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=footer). Last update [c65a0f5...f457e43](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=h1) Report
> Merging [#18049](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/c65a0f554b0381ac3f50762050a56bcff188ffa1?src=pr&el=desc) will **decrease** coverage by `0.01%`.
> The diff coverage is `n/a`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/18049/graphs/tree.svg?width=650&src=pr&token=eZ4WkYLtcO&height=150)](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=tree)

```diff
@@            Coverage Diff             @@
##           master   #18049      +/-   ##
==========================================
- Coverage   91.24%   91.23%   -0.02%     
==========================================
  Files         163      163              
  Lines       50114    50114              
==========================================
- Hits        45729    45720       -9     
- Misses       4385     4394       +9
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `89.04% <ø> (ø)` | :arrow_up: |
| #single | `40.24% <ø> (-0.06%)` | :arrow_down: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/io/gbq.py](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=tree#diff-cGFuZGFzL2lvL2dicS5weQ==) | `25% <0%> (-58.34%)` | :arrow_down: |
| [pandas/core/frame.py](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvZnJhbWUucHk=) | `97.75% <0%> (-0.1%)` | :arrow_down: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=footer). Last update [c65a0f5...f457e43](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=h1) Report
> Merging [#18049](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/c65a0f554b0381ac3f50762050a56bcff188ffa1?src=pr&el=desc) will **decrease** coverage by `0.01%`.
> The diff coverage is `n/a`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/18049/graphs/tree.svg?width=650&height=150&src=pr&token=eZ4WkYLtcO)](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=tree)

```diff
@@            Coverage Diff             @@
##           master   #18049      +/-   ##
==========================================
- Coverage   91.24%   91.23%   -0.02%     
==========================================
  Files         163      163              
  Lines       50114    50114              
==========================================
- Hits        45729    45720       -9     
- Misses       4385     4394       +9
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `89.04% <ø> (ø)` | :arrow_up: |
| #single | `40.24% <ø> (-0.06%)` | :arrow_down: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/io/gbq.py](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=tree#diff-cGFuZGFzL2lvL2dicS5weQ==) | `25% <0%> (-58.34%)` | :arrow_down: |
| [pandas/core/frame.py](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvZnJhbWUucHk=) | `97.75% <0%> (-0.1%)` | :arrow_down: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=footer). Last update [c65a0f5...f457e43](https://codecov.io/gh/pandas-dev/pandas/pull/18049?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

the clipboard tests are orthogonal to this. They fail occasionally, a restart of the job usually fixes. 

However the is_bool_array is faulting somewhere in cython.
thanks!