diff options
author | Jeremy Kemper <jeremy@bitsweat.net> | 2008-09-04 17:20:07 +0200 |
---|---|---|
committer | Jeremy Kemper <jeremy@bitsweat.net> | 2008-09-04 17:20:07 +0200 |
commit | cd498e25887cafc5d2b0d427b3f87af9f648aff5 (patch) | |
tree | db8a5afe348ccc89a9a0f78786cdaa77cd0c7b70 /activerecord/test/cases | |
parent | 17628ecfce14abf4f9977300e19f3433488e668f (diff) | |
download | rails-cd498e25887cafc5d2b0d427b3f87af9f648aff5.tar.gz rails-cd498e25887cafc5d2b0d427b3f87af9f648aff5.tar.bz2 rails-cd498e25887cafc5d2b0d427b3f87af9f648aff5.zip |
Rescue spurious failures in case dummy postgresql user or schema already exists
Diffstat (limited to 'activerecord/test/cases')
-rw-r--r-- | activerecord/test/cases/schema_authorization_test_postgresql.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/test/cases/schema_authorization_test_postgresql.rb b/activerecord/test/cases/schema_authorization_test_postgresql.rb index 7a0796ef53..ba7754513d 100644 --- a/activerecord/test/cases/schema_authorization_test_postgresql.rb +++ b/activerecord/test/cases/schema_authorization_test_postgresql.rb @@ -18,8 +18,8 @@ class SchemaAuthorizationTest < ActiveRecord::TestCase @connection.execute "SET search_path TO '$user',public" set_session_auth USERS.each do |u| - @connection.execute "CREATE USER #{u}" - @connection.execute "CREATE SCHEMA AUTHORIZATION #{u}" + @connection.execute "CREATE USER #{u}" rescue nil + @connection.execute "CREATE SCHEMA AUTHORIZATION #{u}" rescue nil set_session_auth u @connection.execute "CREATE TABLE #{TABLE_NAME} (#{COLUMNS.join(',')})" @connection.execute "INSERT INTO #{TABLE_NAME} (name) VALUES ('#{u}')" |