Sha256: 4bb7a6352e3c6ecd284bdd02574493129b65c29fea4d61e1644539a4028bab40
Contents?: true
Size: 1.1 KB
Versions: 8
Compression:
Stored size: 1.1 KB
Contents
require 'spec_helper' pwd = File.join(Dir.pwd, "generator_tests") EXPECTED_FILES = %w( app/controllers/application_controller.js app/helpers/application_helper.js app/models/ app/resources/ app/views/ config/application.rb config/routes.rb config/boot.rb public/webgl_not_supported.html script/jax spec/javascripts/support/jasmine.yml spec/javascripts/support/jasmine_runner.rb spec/javascripts/support/spec_layout.html.erb spec/javascripts/support/spec_helpers/jax_spec_helper.js Rakefile Gemfile ) describe Jax::Generators::App::AppGenerator do def generate(*args) Jax::Generators::App::AppGenerator.start(args + ['--debug'], :shell => SpecShell.new) end before :each do FileUtils.rm_rf pwd Dir.chdir File.expand_path('..', pwd) FileUtils.mkdir_p pwd Dir.chdir pwd end after :each do FileUtils.rm_rf pwd Dir.chdir File.expand_path('..', pwd) end EXPECTED_FILES.each do |file| it "should generate '#{file}'" do generate("test_app") File.should exist(File.expand_path(File.join("test_app", file), pwd)) end end end
Version data entries
8 entries across 8 versions & 1 rubygems