Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

asakusa.rb hack night!

Fix in-memory tests
  • Loading branch information...
commit 79238bad3debae3c36f6e37c4057b30324731b0c 1 parent 4c1c2e6
@tenderlove tenderlove authored
View
2  activerecord/test/cases/scoping/default_scoping_test.rb
@@ -55,6 +55,8 @@ def test_default_scope_with_conditions_hash
end
def test_default_scoping_with_threads
+ skip "in-memory database mustn't disconnect" if in_memory_db?
+
2.times do
Thread.new {
assert DeveloperOrderedBySalary.all.to_sql.include?('salary DESC')
View
3  activerecord/test/cases/transactions_test.rb
@@ -545,6 +545,9 @@ class ConcurrentTransactionTest < TransactionTest
# This will cause transactions to overlap and fail unless they are performed on
# separate database connections.
def test_transaction_per_thread
+ if in_memory_db?
+ skip "in memory db can't share a db between threads"
+ end
threads = 3.times.map do
Thread.new do
Topic.transaction do
Please sign in to comment.
Something went wrong with that request. Please try again.