From 32e1cc2deea5591605d7c8df80d730a66d280c2e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felix=20Sch=C3=A4fer?= Date: Sat, 9 Jun 2012 09:41:23 +0200 Subject: [PATCH] Don't test transaction-based features on SQLite SQLite doesn't support nested transactions, thus we can't test transaction-based features inside a test wrapped in a transaction. --- test/functional/project_enumerations_controller_test.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/functional/project_enumerations_controller_test.rb b/test/functional/project_enumerations_controller_test.rb index 5da7ed24..6514f457 100644 --- a/test/functional/project_enumerations_controller_test.rb +++ b/test/functional/project_enumerations_controller_test.rb @@ -131,6 +131,10 @@ class ProjectEnumerationsControllerTest < ActionController::TestCase end def test_update_when_creating_new_activities_will_not_convert_existing_data_if_an_exception_is_raised + # SQLite doesn't support nested transactions, thus we can't test transaction- + # based features in a test wrapped in a transaction. + return if ChiliProject::Database.sqlite? + # TODO: Need to cause an exception on create but these tests # aren't setup for mocking. Just create a record now so the # second one is a dupicate