diff options
author | José Valim <jose.valim@gmail.com> | 2009-06-19 16:10:24 +0200 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2009-06-19 16:10:24 +0200 |
commit | 8037fee9ff1dd13c421e6689229457c1ef084074 (patch) | |
tree | c60b2bf3e297be3e1bccb64ffd034acb137a7aa8 /actionpack/test/lib/fixture_template.rb | |
parent | 908b5305d4446433433313e315deb4083c58233e (diff) | |
parent | 9f7eaea201b2f408d9effbf82f2731957e284adf (diff) | |
download | rails-8037fee9ff1dd13c421e6689229457c1ef084074.tar.gz rails-8037fee9ff1dd13c421e6689229457c1ef084074.tar.bz2 rails-8037fee9ff1dd13c421e6689229457c1ef084074.zip |
Merge branch 'master' of git://github.com/rails/rails
Diffstat (limited to 'actionpack/test/lib/fixture_template.rb')
-rw-r--r-- | actionpack/test/lib/fixture_template.rb | 41 |
1 files changed, 2 insertions, 39 deletions
diff --git a/actionpack/test/lib/fixture_template.rb b/actionpack/test/lib/fixture_template.rb index 59fb6819ed..5cf414a1c6 100644 --- a/actionpack/test/lib/fixture_template.rb +++ b/actionpack/test/lib/fixture_template.rb @@ -1,6 +1,5 @@ module ActionView #:nodoc: -class Template - class FixturePath < Path + class FixtureResolver < Resolver def initialize(hash = {}, options = {}) super(options) @hash = hash @@ -22,7 +21,7 @@ class Template def formats_regexp @formats_regexp ||= begin - formats = Mime::SET.map { |m| m.symbol } + formats = Mime::SET.symbols '(?:' + formats.map { |l| "\\.#{Regexp.escape(l.to_s)}" }.join('|') + ')?' end end @@ -65,40 +64,4 @@ class Template end end end - - - # class FixtureTemplate < Template - # class FixturePath < Template::Path - # def initialize(hash = {}) - # @hash = {} - # - # hash.each do |k, v| - # @hash[k.sub(/\.\w+$/, '')] = FixtureTemplate.new(v, k.split("/").last, self) - # end - # - # super("fixtures://root") - # end - # - # def find_template(path) - # @hash[path] - # end - # end - # - # def initialize(body, *args) - # @body = body - # super(*args) - # end - # - # def source - # @body - # end - # - # private - # - # def find_full_path(path, load_paths) - # return '/', path - # end - # - # end -end end
\ No newline at end of file |