|
20 | 20 | from pandas import (DataFrame, Index, Series, isnull,
|
21 | 21 | MultiIndex, Timedelta, Timestamp,
|
22 | 22 | date_range)
|
23 |
| -from pandas.errors import PandasError |
24 | 23 | import pandas as pd
|
25 | 24 | import pandas._libs.lib as lib
|
26 | 25 | import pandas.util.testing as tm
|
@@ -773,7 +772,7 @@ def test_constructor_more(self):
|
773 | 772 |
|
774 | 773 | # corner, silly
|
775 | 774 | # TODO: Fix this Exception to be better...
|
776 |
| - with tm.assertRaisesRegexp(PandasError, 'constructor not ' |
| 775 | + with tm.assertRaisesRegexp(ValueError, 'constructor not ' |
777 | 776 | 'properly called'):
|
778 | 777 | DataFrame((1, 2, 3))
|
779 | 778 |
|
@@ -1241,8 +1240,8 @@ def test_constructor_single_value(self):
|
1241 | 1240 | dtype=object),
|
1242 | 1241 | index=[1, 2], columns=['a', 'c']))
|
1243 | 1242 |
|
1244 |
| - self.assertRaises(PandasError, DataFrame, 'a', [1, 2]) |
1245 |
| - self.assertRaises(PandasError, DataFrame, 'a', columns=['a', 'c']) |
| 1243 | + self.assertRaises(ValueError, DataFrame, 'a', [1, 2]) |
| 1244 | + self.assertRaises(ValueError, DataFrame, 'a', columns=['a', 'c']) |
1246 | 1245 | with tm.assertRaisesRegexp(TypeError, 'incompatible data and dtype'):
|
1247 | 1246 | DataFrame('a', [1, 2], ['a', 'c'], float)
|
1248 | 1247 |
|
|
0 commit comments