mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Ensure that mini_magick
is absent after rails new
with --skip-active-storage
Remove redundant assertions of an absence of `mini_magick` in `Gemfile`
since `bin/rails app:update` does not update Gemfile.
This assertions was added by 4a835aa323
,
after reviewing of https://github.com/rails/rails/pull/32049 i realized
that assertions are redundant.
This commit is contained in:
parent
ffddaead04
commit
c335066b9d
1 changed files with 9 additions and 8 deletions
|
@ -315,6 +315,15 @@ class AppGeneratorTest < Rails::Generators::TestCase
|
||||||
assert_file "Gemfile", /^# gem 'mini_magick'/
|
assert_file "Gemfile", /^# gem 'mini_magick'/
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def test_mini_magick_gem_when_skip_active_storage_is_given
|
||||||
|
app_root = File.join(destination_root, "myapp")
|
||||||
|
run_generator [app_root, "--skip-active-storage"]
|
||||||
|
|
||||||
|
assert_file "#{app_root}/Gemfile" do |content|
|
||||||
|
assert_no_match(/gem 'mini_magick'/, content)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
def test_app_update_does_not_generate_active_storage_contents_when_skip_active_storage_is_given
|
def test_app_update_does_not_generate_active_storage_contents_when_skip_active_storage_is_given
|
||||||
app_root = File.join(destination_root, "myapp")
|
app_root = File.join(destination_root, "myapp")
|
||||||
run_generator [app_root, "--skip-active-storage"]
|
run_generator [app_root, "--skip-active-storage"]
|
||||||
|
@ -336,10 +345,6 @@ class AppGeneratorTest < Rails::Generators::TestCase
|
||||||
end
|
end
|
||||||
|
|
||||||
assert_no_file "#{app_root}/config/storage.yml"
|
assert_no_file "#{app_root}/config/storage.yml"
|
||||||
|
|
||||||
assert_file "#{app_root}/Gemfile" do |content|
|
|
||||||
assert_no_match(/gem 'mini_magick'/, content)
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_app_update_does_not_generate_active_storage_contents_when_skip_active_record_is_given
|
def test_app_update_does_not_generate_active_storage_contents_when_skip_active_record_is_given
|
||||||
|
@ -363,10 +368,6 @@ class AppGeneratorTest < Rails::Generators::TestCase
|
||||||
end
|
end
|
||||||
|
|
||||||
assert_no_file "#{app_root}/config/storage.yml"
|
assert_no_file "#{app_root}/config/storage.yml"
|
||||||
|
|
||||||
assert_file "#{app_root}/Gemfile" do |content|
|
|
||||||
assert_no_match(/gem 'mini_magick'/, content)
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_app_update_does_not_change_config_target_version
|
def test_app_update_does_not_change_config_target_version
|
||||||
|
|
Loading…
Reference in a new issue