Skip to content
This repository
Fetching contributors…

Cannot retrieve contributors at this time

file 31 lines (23 sloc) 0.773 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
# -*- ruby -*-

require 'autotest/restart'

Autotest.add_hook :initialize do |at|
  at.order = :natural # I am a bad person - Eric Hodel
  at.testlib = 'minitest/unit' if at.respond_to? :testlib=

  at.add_exception %r%/\.svn/%
  at.add_exception %r%\.rbc$%
  at.add_exception %r%test/rubygems%

  at.find_directories.clear
  at.find_directories.push 'lib', 'test'

  at.add_mapping %r%^lib/rubygems.rb$% do |_, m|
    "test/test_gem.rb"
  end

  at.add_mapping %r%^lib/rubygems/(.*).rb$% do |_, m|
    "test/test_gem_#{m[1].gsub '/', '_'}.rb"
  end

  at.add_mapping %r%^test/support/(.*).rb$% do |_, m|
    at.files_matching %r%^test/test_(.*)\.rb$%
  end

  # at.add_mapping %r%^test/support/(.*).rb$% do |_, m|
  # files_matching %r%^test/test_(.*)\.rb%%
  # end
end
Something went wrong with that request. Please try again.