From 3bb9f2e27ee5f4e48aeaf86eb8c6cdaf5bf0daff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9my=20L=C3=A9one?= Date: Sat, 7 Nov 2015 10:07:20 +0100 Subject: [PATCH] CLN: Remove useless semicolon --- pandas/io/tests/test_json/test_ujson.py | 6 +++--- pandas/tests/test_series.py | 4 ++-- pandas/util/testing.py | 10 +++++----- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/pandas/io/tests/test_json/test_ujson.py b/pandas/io/tests/test_json/test_ujson.py index 8e8a798b2e792..9590dbb90e5c6 100644 --- a/pandas/io/tests/test_json/test_ujson.py +++ b/pandas/io/tests/test_json/test_ujson.py @@ -1004,7 +1004,7 @@ def testFloatMax(self): assert_approx_equal(np.float64(ujson.decode(ujson.encode(num, double_precision=15))), num, 15) def testArrays(self): - arr = np.arange(100); + arr = np.arange(100) arr = arr.reshape((10, 10)) tm.assert_numpy_array_equal(np.array(ujson.decode(ujson.encode(arr))), arr) @@ -1018,7 +1018,7 @@ def testArrays(self): tm.assert_numpy_array_equal(np.array(ujson.decode(ujson.encode(arr))), arr) tm.assert_numpy_array_equal(ujson.decode(ujson.encode(arr), numpy=True), arr) - arr = np.arange(96); + arr = np.arange(96) arr = arr.reshape((2, 2, 2, 2, 3, 2)) tm.assert_numpy_array_equal(np.array(ujson.decode(ujson.encode(arr))), arr) tm.assert_numpy_array_equal(ujson.decode(ujson.encode(arr), numpy=True), arr) @@ -1028,7 +1028,7 @@ def testArrays(self): arr = np.array(l) tm.assert_numpy_array_equal(np.array(ujson.decode(ujson.encode(arr))), arr) - arr = np.arange(100.202, 200.202, 1, dtype=np.float32); + arr = np.arange(100.202, 200.202, 1, dtype=np.float32) arr = arr.reshape((5, 5, 4)) outp = np.array(ujson.decode(ujson.encode(arr)), dtype=np.float32) assert_array_almost_equal_nulp(arr, outp) diff --git a/pandas/tests/test_series.py b/pandas/tests/test_series.py index 8aed49a7e6c3f..1c8cbac60e7c7 100644 --- a/pandas/tests/test_series.py +++ b/pandas/tests/test_series.py @@ -6074,7 +6074,7 @@ def test_getitem_setitem_datetimeindex(self): assert_series_equal(result, ts) def test_getitem_setitem_datetime_tz_pytz(self): - tm._skip_if_no_pytz(); + tm._skip_if_no_pytz() from pytz import timezone as tz from pandas import date_range @@ -6110,7 +6110,7 @@ def test_getitem_setitem_datetime_tz_pytz(self): def test_getitem_setitem_datetime_tz_dateutil(self): - tm._skip_if_no_dateutil(); + tm._skip_if_no_dateutil() from dateutil.tz import tzutc from pandas.tslib import _dateutil_gettz as gettz diff --git a/pandas/util/testing.py b/pandas/util/testing.py index a278c4d0f9045..be8b0df73593f 100644 --- a/pandas/util/testing.py +++ b/pandas/util/testing.py @@ -1886,7 +1886,7 @@ def assertRaises(_exception, _callable=None, *args, **kwargs): In addition to using it as a contextmanager, you can also use it as a function, just like the normal assertRaises - >>> assertRaises(TypeError, ",".join, [1, 3, 5]); + >>> assertRaises(TypeError, ",".join, [1, 3, 5]) """ manager = _AssertRaisesContextmanager(exception=_exception) # don't return anything if used in function form @@ -1907,18 +1907,18 @@ def assertRaisesRegexp(_exception, _regexp, _callable=None, *args, **kwargs): You can pass either a regular expression or a compiled regular expression object. >>> assertRaisesRegexp(ValueError, 'invalid literal for.*XYZ', - ... int, 'XYZ'); + ... int, 'XYZ') >>> import re - >>> assertRaisesRegexp(ValueError, re.compile('literal'), int, 'XYZ'); + >>> assertRaisesRegexp(ValueError, re.compile('literal'), int, 'XYZ') If an exception of a different type is raised, it bubbles up. - >>> assertRaisesRegexp(TypeError, 'literal', int, 'XYZ'); + >>> assertRaisesRegexp(TypeError, 'literal', int, 'XYZ') Traceback (most recent call last): ... ValueError: invalid literal for int() with base 10: 'XYZ' >>> dct = dict() - >>> assertRaisesRegexp(KeyError, 'pear', dct.__getitem__, 'apple'); + >>> assertRaisesRegexp(KeyError, 'pear', dct.__getitem__, 'apple') Traceback (most recent call last): ... AssertionError: "pear" does not match "'apple'"