使用 Rails 3.1.x、DatabaseCleaner gem 和 capybara 2,我在尝试运行测试时得到以下信息:
Failure/Error: Unable to find matching line from backtrace
ActiveRecord::StatementInvalid:
Mysql2::Error: Table 'teambox_test_default.incoming_emails' doesn't exist: TRUNCATE TABLE incoming_emails
# ./config/initializers/connection_fix.rb:24:in `execute'
# -e:1:in `<main>'