[rspec-users] Sharing: dont_repeat_yourself plugin custom RSpec matcher

21croissants address4spams at 21croissants.com
Tue Apr 29 13:25:30 EDT 2008


I wrote a Rails plugin which uses simian to look for duplicates lines in your
code and reports in html format, Textmate or Netbeans.

I wrote it using RSpec and I have included a RSpec custom matcher:
it { rails_application.
with_threshold_of_duplicate_lines(4).
  should be_DRY }

If you use Autotest, your specs will fail the next time you do a nasty
copy-paste !!!

More details in http://21croissants.blogspot.com/2008/03/dry.html

Feedback and patches (with specs!) welcome ;-)

Jean-Michel
-- 
View this message in context: http://www.nabble.com/Sharing%3A-dont_repeat_yourself-plugin-custom-RSpec-matcher-tp16965619p16965619.html
Sent from the rspec-users mailing list archive at Nabble.com.



More information about the rspec-users mailing list