Sha256: ae226c7398d8516cefa242d1e3bf3b2fb8ab61c93b1a18885f3460a1c596b399

Contents?: true

Size: 699 Bytes

Versions: 54

Compression:

Stored size: 699 Bytes

Contents

#
# Convenience Methods
#
def run(cmd)
  print "\n\n"
  puts(cmd)
  system(cmd)
  print "\n\n"
end

def run_all_tests
  # see Rakefile for the definition of the test:all task
  system("rake -s test:all VERBOSE=true")
end

#
# Watchr Rules
#
watch('^test/.*?_test\.rb'   ) {|m| run("ruby -rubygems %s"              % m[0]) }
watch('^lib/(.*)\.rb'        ) {|m| run("ruby -rubygems test/%s_test.rb" % m[1]) }
watch('^lib/toto/(.*)\.rb'   ) {|m| run("ruby -rubygems test/%s_test.rb" % m[1]) }
watch('^test/test_helper\.rb') { run_all_tests }

#
# Signal Handling
#
# Ctrl-\
Signal.trap('QUIT') do
  puts " --- Running all tests ---\n\n"
  run_all_tests
end

# Ctrl-C
Signal.trap('INT') { abort("\n") }

Version data entries

54 entries across 54 versions & 11 rubygems

Version Path
ceilingfish-toto-0.4.3 test/autotest.rb
ceilingfish-toto-0.4.2 test/autotest.rb
ceilingfish-toto-0.4.0 test/autotest.rb
toto-0.4.1 test/autotest.rb
toto-0.4.0 test/autotest.rb
ceilingfish-toto-0.3.9 test/autotest.rb
ceilingfish-toto-0.3.8 test/autotest.rb
ceilingfish-toto-0.3.7 test/autotest.rb
ceilingfish-toto-0.3.6 test/autotest.rb
toto-0.3.3 test/autotest.rb
ceilingfish-toto-0.3.5 test/autotest.rb
ceilingfish-toto-0.3.4 test/autotest.rb
ceilingfish-toto-0.3.2 test/autotest.rb
toto-haml-0.3.3 test/autotest.rb
toto-haml-0.3.2 test/autotest.rb
toto-0.3.2 test/autotest.rb
toto-0.3.1 test/autotest.rb
toto-0.3.0 test/autotest.rb
toto-0.2.8 test/autotest.rb
toto-0.2.7 test/autotest.rb