From 63c6409afaee9593f677e565fcb0381da7ab430b Mon Sep 17 00:00:00 2001 From: Steve Polito Date: Fri, 16 Feb 2024 05:59:47 -0500 Subject: [PATCH] Clean up `suspenders:setup` Follow-up to #1157 Removes obsolete files and test helpers. --- lib/generators/templates/setup/dev_prime.rb | 12 ------------ test/generators/suspenders/setup_generator_test.rb | 2 -- 2 files changed, 14 deletions(-) delete mode 100644 lib/generators/templates/setup/dev_prime.rb diff --git a/lib/generators/templates/setup/dev_prime.rb b/lib/generators/templates/setup/dev_prime.rb deleted file mode 100644 index 44da79691..000000000 --- a/lib/generators/templates/setup/dev_prime.rb +++ /dev/null @@ -1,12 +0,0 @@ -if Rails.env.development? || Rails.env.test? - require "factory_bot" if Bundler.rubygems.find_name("factory_bot_rails").any? - - namespace :dev do - desc "Sample data for local development environment" - task prime: "db:setup" do - include FactoryBot::Syntax::Methods if Bundler.rubygems.find_name("factory_bot_rails").any? - - # create(:user, email: "user@example.com", password: "password") - end - end -end diff --git a/test/generators/suspenders/setup_generator_test.rb b/test/generators/suspenders/setup_generator_test.rb index e3396ba2b..c8db00da3 100644 --- a/test/generators/suspenders/setup_generator_test.rb +++ b/test/generators/suspenders/setup_generator_test.rb @@ -32,9 +32,7 @@ def prepare_destination end def restore_destination - remove_file_if_exists "Brewfile" restore_file "bin/setup" - remove_dir_if_exists "lib/tasks" end def bin_setup