Permalink
Browse files

Fix plugin_new test failure from c8c8439

`plugin_new` generator doesn't generate `sass-rails` in the Gemfile, so
you can't check for that.
  • Loading branch information...
1 parent 0696a51 commit b673ca68f1d8e061dc9d4819bc0a1ba4935b2671 @sikachu sikachu committed Feb 1, 2012
@@ -133,6 +133,13 @@ def test_gemfile_has_no_whitespace_errors
end
end
+ def test_edge_gemfile_option
+ generator([destination_root], :edge => true).expects(:bundle_command).with('install').once
+ quietly { generator.invoke_all }
+ assert_file 'Gemfile', %r{^\s+gem\s+["']sass-rails["'],\s+:git\s+=>\s+["']#{Regexp.escape("git://github.com/rails/sass-rails.git")}["']$}
+ assert_file 'Gemfile', %r{^\s+gem\s+["']coffee-rails["'],\s+:git\s+=>\s+["']#{Regexp.escape("git://github.com/rails/coffee-rails.git")}["']$}
+ end
+
def test_config_database_is_added_by_default
run_generator
assert_file "config/database.yml", /sqlite3/
@@ -128,9 +128,6 @@ def test_edge_option
assert_file 'Gemfile', %r{^gem\s+["']rails["'],\s+:git\s+=>\s+["']#{Regexp.escape("git://github.com/rails/rails.git")}["']$}
assert_file 'Gemfile', %r{^gem\s+["']journey["'],\s+:git\s+=>\s+["']#{Regexp.escape("git://github.com/rails/journey.git")}["']$}
assert_file 'Gemfile', %r{^gem\s+["']arel["'],\s+:git\s+=>\s+["']#{Regexp.escape("git://github.com/rails/arel.git")}["']$}
-
- assert_file 'Gemfile', %r{^\s+gem\s+["']sass-rails["'],\s+:git\s+=>\s+["']#{Regexp.escape("git://github.com/rails/sass-rails.git")}["']$}
- assert_file 'Gemfile', %r{^\s+gem\s+["']coffee-rails["'],\s+:git\s+=>\s+["']#{Regexp.escape("git://github.com/rails/coffee-rails.git")}["']$}
end
def test_skip_gemfile

0 comments on commit b673ca6

Please sign in to comment.