diff options
author | Rafael França <rafaelmfranca@gmail.com> | 2016-07-05 13:07:24 -0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-07-05 13:07:24 -0300 |
commit | aed11fdc7c07e42fbaefb5110f5ee5eab2db5a3e (patch) | |
tree | 5e1eea9275fb41c061e5d393275a11209244f618 /railties/test | |
parent | 50819394c8f27fe5343af8398add790d62d63619 (diff) | |
parent | 22a94d9ac4be7c1ee0482f671cd7d0ae6dd7cca5 (diff) | |
download | rails-aed11fdc7c07e42fbaefb5110f5ee5eab2db5a3e.tar.gz rails-aed11fdc7c07e42fbaefb5110f5ee5eab2db5a3e.tar.bz2 rails-aed11fdc7c07e42fbaefb5110f5ee5eab2db5a3e.zip |
Merge pull request #25692 from johnmeehan/allow-registering-directory-for-rake-notes
Allow rake notes to work with other directories.
Diffstat (limited to 'railties/test')
-rw-r--r-- | railties/test/application/rake/notes_test.rb | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/railties/test/application/rake/notes_test.rb b/railties/test/application/rake/notes_test.rb index 50def9beb0..a94e302099 100644 --- a/railties/test/application/rake/notes_test.rb +++ b/railties/test/application/rake/notes_test.rb @@ -126,6 +126,18 @@ module ApplicationTests end end + test 'register additional directories' do + app_file "spec/spec_helper.rb", "# TODO: note in spec" + app_file "spec/models/user_spec.rb", "# TODO: note in model spec" + add_to_config %q{ config.annotations.register_directories("spec") } + + run_rake_notes do |output, lines| + assert_match(/note in spec/, output) + assert_match(/note in model spec/, output) + assert_equal 2, lines.size + end + end + private def run_rake_notes(command = 'bin/rails notes') |