diff options
author | José Valim <jose.valim@gmail.com> | 2010-03-21 19:30:42 +0100 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2010-03-21 19:30:42 +0100 |
commit | 8b50f89ba7076a62595d040f1512859c287c2d5c (patch) | |
tree | c94aad953c6b6a4eebcb09593abfa76219cf0d12 /railties/test/generators | |
parent | 87db863fa212abd45be008c40ba1fb7ea26b6b60 (diff) | |
download | rails-8b50f89ba7076a62595d040f1512859c287c2d5c.tar.gz rails-8b50f89ba7076a62595d040f1512859c287c2d5c.tar.bz2 rails-8b50f89ba7076a62595d040f1512859c287c2d5c.zip |
Make ERB generators more flexible and customizable.
Diffstat (limited to 'railties/test/generators')
-rw-r--r-- | railties/test/generators/mailer_generator_test.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/railties/test/generators/mailer_generator_test.rb b/railties/test/generators/mailer_generator_test.rb index e6fc1bbb5c..abbca5852b 100644 --- a/railties/test/generators/mailer_generator_test.rb +++ b/railties/test/generators/mailer_generator_test.rb @@ -29,19 +29,19 @@ class MailerGeneratorTest < Rails::Generators::TestCase def test_invokes_default_test_framework run_generator assert_file "test/functional/notifier_test.rb", /class NotifierTest < ActionMailer::TestCase/ - assert_file "test/fixtures/notifier/foo", /app\/views\/notifier\/foo/ - assert_file "test/fixtures/notifier/bar", /app\/views\/notifier\/bar/ + assert_file "test/fixtures/notifier/foo", /app\/views\/notifier\/foo$/ + assert_file "test/fixtures/notifier/bar", /app\/views\/notifier\/bar$/ end def test_invokes_default_template_engine run_generator assert_file "app/views/notifier/foo.text.erb" do |view| - assert_match /app\/views\/notifier\/foo/, view + assert_match /app\/views\/notifier\/foo$/, view assert_match /<%= @greeting %>/, view end assert_file "app/views/notifier/bar.text.erb" do |view| - assert_match /app\/views\/notifier\/bar/, view + assert_match /app\/views\/notifier\/bar$/, view assert_match /<%= @greeting %>/, view end end |