Sha256: b8167a7c3674e79f11ecdb2f3732ba942fbe691e15c48df556e0672542cb3c31

Contents?: true

Size: 670 Bytes

Versions: 4

Compression:

Stored size: 670 Bytes

Contents

#require File.expand_path('../lib/generators/layout/layout_generator', File.dirname(__FILE__))
require 'test_helper'
require 'generators/layout/layout_generator'

class LayoutGeneratorTest < Rails::Generators::TestCase
  tests LayoutGenerator
  destination File.expand_path("./tmp", File.dirname(__FILE__))
  def setup
    FileUtils.rm_rf(File.expand_path("./tmp/.", File.dirname(__FILE__)))
  end

  test "Assert all files are properly created" do
    run_generator %w(simple)
    assert_directory "public/simple/images"
    assert_file "public/simple/styles.css"
    assert_file "public/simple/index.html"
    assert_file "app/views/layouts/simple.html.erb"
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
simple-layout-0.4.0 test/layout_generator_test.rb
simple-layout-0.3.1 test/layout_generator_test.rb
simple-layout-0.3.0 test/layout_generator_test.rb
simple-layout-0.2.0 test/layout_generator_test.rb