Sha256: 888732576523ba89e234550a0537e62a5f6fc477f0d02b2e76f10ce0f729a0f9
Contents?: true
Size: 1.2 KB
Versions: 20
Compression:
Stored size: 1.2 KB
Contents
require 'test_helper' class InstallGeneratorTest < Rails::Generators::TestCase tests Maestrano::Generators::InstallGenerator destination File.expand_path("../../tmp", __FILE__) setup do prepare_destination copy_routes end should "create the maestrano initializer" do run_generator assert_file "config/initializers/maestrano.rb" end should "create the maestrano/auth/saml_controller" do run_generator assert_file "app/controllers/maestrano/auth/saml_controller.rb" end should "create the maestrano/account/groups_controller" do run_generator assert_file "app/controllers/maestrano/account/groups_controller.rb" end should "create the maestrano/account/group_users_controller" do run_generator assert_file "app/controllers/maestrano/account/group_users_controller.rb" end should "create the maestrano routes" do run_generator match = /maestrano_routes/ assert_file "config/routes.rb", match end def copy_routes routes = File.expand_path("../../test_files/config/routes.rb", __FILE__) destination = File.join(destination_root, "config") FileUtils.mkdir_p(destination) FileUtils.cp routes, destination end end
Version data entries
20 entries across 20 versions & 2 rubygems