Created
July 21, 2012 15:15
-
-
Save thomasfl/3156087 to your computer and use it in GitHub Desktop.
Autorun minitests fast
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'rubygems' | |
| require 'filewatcher' | |
| # Autorun minitests when one of these files is updated: | |
| files = ["my_minitest_tests.rb","code_under_test.rb"] | |
| puts "Update one of these files to start tests: " + files.join(", ") | |
| FileWatcher.new(files).watch do |filename| | |
| puts "Updated " + filename | |
| load filename | |
| MiniTest::Unit.new.run | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment