public
Description: Real HTTP Caching for Ruby Web Apps
Homepage: http://tomayko.com/src/rack-cache/
Clone URL: git://github.com/rtomayko/rack-cache.git
rtomayko (author)
Sat Jun 06 02:10:43 -0700 2009
commit  e51b1fbee7e4cf3e8a8348a0dc9f96d6b9373d5b
tree    d2cf53cd4e9acda46f91f1c6410856bc19a91cf8
parent  12b0de7eaa4801c97a57e6fb3c4bcf2d84056f64
rack-cache / .autotest
100644 24 lines (19 sloc) 0.517 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
Autotest.add_hook :initialize do |t|
  t.clear_mappings
  t.add_exception(/^(?:\/\.)?\.git.*/)
  t.add_exception(/^(?:\/\.)?\[\..*/)
  t.add_mapping(/^lib\/.*\.rb$/) { |fn, _|
    t.files_matching(/^test\/#{File.basename(fn, '.rb')}_test.rb$/) }
  t.add_mapping(/^test\/.*_test\.rb$/) { |fn, _| fn }
 
  def t.path_to_classname(s)
    case s
    when 'test/test_cache.rb'
      "Rack::Cache"
    when /test\/(.*)_test\.rb/
      "Rack::Cache::#{$1.capitalize}"
    else
      super
    end
  end
end
 
 
 
# vim: ft=ruby