Skip to content
This repository has been archived by the owner on Mar 28, 2019. It is now read-only.

Commit

Permalink
Test fix
Browse files Browse the repository at this point in the history
  • Loading branch information
leplatrem committed Nov 9, 2015
1 parent 346a0b0 commit 480713b
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions cliquet/tests/test_views_transaction.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import mock

from cliquet.storage.exceptions import BackendError
from .support import BaseWebTest, unittest
from .support import BaseWebTest, unittest, skip_if_no_postgresql


class PostgreSQLTest(BaseWebTest):
Expand All @@ -12,8 +12,8 @@ def get_app_settings(self, extras=None):
settings = super(PostgreSQLTest, self).get_app_settings(extras)
settings.update(**PostgreSQLStorageTest.settings)
settings.update(**PostgreSQLPermissionTest.settings)
settings.pop('storage_poolclass')
settings.pop('permission_poolclass')
settings.pop('storage_poolclass', None)
settings.pop('permission_poolclass', None)
return settings

def run_failing_batch(self):
Expand Down Expand Up @@ -48,6 +48,7 @@ def run_failing_post(self):
status=503)


@skip_if_no_postgresql
class TransactionTest(PostgreSQLTest, unittest.TestCase):

def test_storage_operations_are_committed_on_success(self):
Expand Down Expand Up @@ -89,6 +90,7 @@ def test_modifications_are_rolled_back_on_error_accross_backends(self):
self.assertEqual(len(resp.json['data']), 0)


@skip_if_no_postgresql
class WithoutTransactionTest(PostgreSQLTest, unittest.TestCase):

def get_app_settings(self, extras=None):
Expand Down

0 comments on commit 480713b

Please sign in to comment.