[pypy-commit] pypy default: call con.close() to cleanup after test

bdkearns noreply at buildbot.pypy.org
Sun Mar 17 04:59:24 CET 2013


Author: Brian Kearns <bdkearns at gmail.com>
Branch: 
Changeset: r62380:3dd4799bc8c3
Date: 2013-03-16 23:58 -0400
http://bitbucket.org/pypy/pypy/changeset/3dd4799bc8c3/

Log:	call con.close() to cleanup after test

diff --git a/pypy/module/test_lib_pypy/test_sqlite3.py b/pypy/module/test_lib_pypy/test_sqlite3.py
--- a/pypy/module/test_lib_pypy/test_sqlite3.py
+++ b/pypy/module/test_lib_pypy/test_sqlite3.py
@@ -159,6 +159,7 @@
         con.commit()
     except _sqlite3.OperationalError:
         pytest.fail("_sqlite3 knew nothing about the implicit ROLLBACK")
+    con.close()
 
 def test_statement_arg_checking():
     con = _sqlite3.connect(':memory:')
@@ -194,3 +195,4 @@
     with pytest.raises(ValueError) as e:
         con.execute('insert into foo(x) values (?)', 2)
     assert str(e.value) == 'parameters are of unsupported type'
+    con.close()


More information about the pypy-commit mailing list