Mercurial > p > roundup > code
diff test/test_postgresql.py @ 5310:efb34cbdba7c
Add (currently failing) test for atomic actions
Actions via the web-interface can have several database-modifying
instructions. These should be atomic, i.e., either all should go in or
none. This is currently not the case due to commit calls from OTK
handling (CSRF-protection).
| author | Ralf Schlatterbeck <rsc@runtux.com> |
|---|---|
| date | Mon, 06 Nov 2017 09:26:59 +0100 |
| parents | 198b6e810c67 |
| children | 62de601bdf6f |
line wrap: on
line diff
--- a/test/test_postgresql.py Wed Oct 25 23:07:35 2017 -0400 +++ b/test/test_postgresql.py Mon Nov 06 09:26:59 2017 +0100 @@ -23,7 +23,7 @@ from db_test_base import DBTest, ROTest, config, SchemaTest, ClassicInitTest from db_test_base import ConcurrentDBTest, HTMLItemTest, FilterCacheTest -from db_test_base import ClassicInitBase, setupTracker +from db_test_base import ClassicInitBase, setupTracker, SpecialActionTest if not have_backend('postgresql'): # FIX: workaround for a bug in pytest.mark.skip(): @@ -213,4 +213,16 @@ RDBMSTest.tearDown(self) postgresqlOpener.tearDown(self) +@skip_postgresql +class postgresqlSpecialActionTestCase(postgresqlOpener, SpecialActionTest, + unittest.TestCase): + backend = 'postgresql' + def setUp(self): + postgresqlOpener.setUp(self) + SpecialActionTest.setUp(self) + + def tearDown(self): + SpecialActionTest.tearDown(self) + postgresqlOpener.tearDown(self) + # vim: set et sts=4 sw=4 :
