Sha256: d8959617b899dedf8a493c110f7d01290ad83dffd8c7318baf56572ade3e4e96
Contents?: true
Size: 717 Bytes
Versions: 2
Compression:
Stored size: 717 Bytes
Contents
require File.expand_path("spec_helper", File.dirname(File.dirname(__FILE__))) describe "static plugin" do it "adds support for serving static files" do app(:bare) do plugin :static, ['/about'], :root=>'spec/views' route do 'a' end end body.should == 'a' body('/about/_test.erb').should == File.read('spec/views/about/_test.erb') end it "respects the application's :root option" do app(:bare) do opts[:root] = File.expand_path('../../', __FILE__) plugin :static, ['/about'], :root=>'views' route do 'a' end end body.should == 'a' body('/about/_test.erb').should == File.read('spec/views/about/_test.erb') end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
roda-2.2.0 | spec/plugin/static_spec.rb |
roda-2.1.0 | spec/plugin/static_spec.rb |