diff --git a/README.md b/README.md index e431264..94be9e8 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,5 @@ Use Guard with Hydra and get super-parallel test execution! Awesome! - Options: * `:runner_log`: The location of the runner log where output is printed diff --git a/lib/guard/hydra/templates/Guardfile b/lib/guard/hydra/templates/Guardfile index 255d427..7c8f127 100644 --- a/lib/guard/hydra/templates/Guardfile +++ b/lib/guard/hydra/templates/Guardfile @@ -1,4 +1,10 @@ guard 'hydra' do # All spec files - watch(%r{spec/**/*_spec.rb}) + watch(%r{^spec/**/*_spec.rb$}) + + # All lib files + watch(%r{^lib/(.*)\.rb$}) { |m| "spec/lib/#{m[1]}_spec.rb" } + + # All app files for a Rails app + watch(%r{^app/(.*)\.rb$}) { |m| "spec/#{m[1]}_spec.rb" } end