test/generators/buildybuild/cms/cms_generator_test.rb in buildybuild-0.0.1 vs test/generators/buildybuild/cms/cms_generator_test.rb in buildybuild-1.0.0

- old
+ new

@@ -10,11 +10,11 @@ assert_file "app/models/page.rb", /class Page/ end test "migration is generated" do generator.generate_migration - assert_migration "db/migrate/create_pages.rb" + assert_migration "db/migrate/create_pages.rb", /create_table :pages/ end test "controller is generated" do generator.generate_controller assert_file "app/controllers/pages_controller.rb" @@ -28,12 +28,11 @@ assert_file "app/views/pages/_form.html.haml", /f\.label :name/ end test "routes are updated" do #create the file in the test so we can insert into it. - generator.create_file("config/routes.rb", "class Routes \n\nend") + generator.create_file("config/routes.rb", "class Routes \n\n end") generator.add_routes assert_file "config/routes.rb", /get "\/:slug", to: "pages#show", as: :slug/ - assert_file "config/routes.rb", /:slug\n\nend$/ end end