Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 2 additions & 6 deletions pandas/tests/computation/test_compat.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,10 @@ def testit():

if engine == "numexpr":
try:
import numexpr as ne
import numexpr as ne # noqa F401
except ImportError:
pytest.skip("no numexpr")
else:
if LooseVersion(ne.__version__) < LooseVersion(VERSIONS["numexpr"]):
with pytest.raises(ImportError):
testit()
else:
testit()
testit()
else:
testit()
4 changes: 2 additions & 2 deletions pandas/tests/io/test_sql.py
Original file line number Diff line number Diff line change
Expand Up @@ -2896,7 +2896,7 @@ def test_execute_fail(self):
sql.execute('INSERT INTO test VALUES("foo", "bar", 1.234)', self.conn)
sql.execute('INSERT INTO test VALUES("foo", "baz", 2.567)', self.conn)

with pytest.raises(Exception):
with pytest.raises(Exception, match="<insert message here>"):
sql.execute('INSERT INTO test VALUES("foo", "bar", 7)', self.conn)

def test_execute_closed_connection(self, request, datapath):
Expand All @@ -2917,7 +2917,7 @@ def test_execute_closed_connection(self, request, datapath):
sql.execute('INSERT INTO test VALUES("foo", "bar", 1.234)', self.conn)
self.conn.close()

with pytest.raises(Exception):
with pytest.raises(Exception, match="<insert message here>"):
tquery("select * from test", con=self.conn)

# Initialize connection again (needed for tearDown)
Expand Down