aboutsummaryrefslogtreecommitdiffstats
path: root/railties/test/application/initializers/frameworks_test.rb
diff options
context:
space:
mode:
Diffstat (limited to 'railties/test/application/initializers/frameworks_test.rb')
-rw-r--r--railties/test/application/initializers/frameworks_test.rb16
1 files changed, 6 insertions, 10 deletions
diff --git a/railties/test/application/initializers/frameworks_test.rb b/railties/test/application/initializers/frameworks_test.rb
index a0e88cd0f0..a08e5b2374 100644
--- a/railties/test/application/initializers/frameworks_test.rb
+++ b/railties/test/application/initializers/frameworks_test.rb
@@ -1,4 +1,5 @@
require "isolation/abstract_unit"
+require 'set'
module ApplicationTests
class FrameworksTest < ActiveSupport::TestCase
@@ -66,7 +67,7 @@ module ApplicationTests
require "#{app_path}/config/environment"
assert Foo.method_defined?(:foo_path)
assert Foo.method_defined?(:main_app)
- assert_equal ["notify"], Foo.action_methods
+ assert_equal Set.new(["notify"]), Foo.action_methods
end
test "allows to not load all helpers for controllers" do
@@ -196,9 +197,8 @@ module ApplicationTests
test "use schema cache dump" do
Dir.chdir(app_path) do
- `rails generate model post title:string`
- `bundle exec rake db:migrate`
- `bundle exec rake db:schema:cache:dump`
+ `rails generate model post title:string;
+ bundle exec rake db:migrate db:schema:cache:dump`
end
require "#{app_path}/config/environment"
ActiveRecord::Base.connection.drop_table("posts") # force drop posts table for test.
@@ -207,17 +207,13 @@ module ApplicationTests
test "expire schema cache dump" do
Dir.chdir(app_path) do
- `rails generate model post title:string`
- `bundle exec rake db:migrate`
- `bundle exec rake db:schema:cache:dump`
-
- `bundle exec rake db:rollback`
+ `rails generate model post title:string;
+ bundle exec rake db:migrate db:schema:cache:dump db:rollback`
end
silence_warnings {
require "#{app_path}/config/environment"
assert !ActiveRecord::Base.connection.schema_cache.tables["posts"]
}
end
-
end
end