Skip to content

Commit

Permalink
Test added by default
Browse files Browse the repository at this point in the history
  • Loading branch information
TomAugspurger committed Dec 1, 2017
1 parent 2cf0601 commit ee7b457
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions pandas/tests/plotting/test_converter.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import subprocess
import pytest
from datetime import datetime, date

Expand All @@ -20,6 +21,15 @@ def test_timtetonum_accepts_unicode():

class TestRegistration(object):

def test_register_by_default(self):
# Run in subprocess to ensure a clean state
code = ("'import matplotlib.units; "
"import pandas as pd; "
"units = dict(matplotlib.units.registry); "
"assert pd.Timestamp in units)'")
call = ['python', '-c', code]
assert subprocess.check_call(call) == 0

def test_warns(self):
plt = pytest.importorskip("matplotlib.pyplot")
s = Series(range(12), index=date_range('2017', periods=12))
Expand Down

0 comments on commit ee7b457

Please sign in to comment.