middleman/features/step_definitions/asset_host_steps.rb

7 lines
271 B
Ruby
Raw Normal View History

2010-02-03 02:03:43 +01:00
Given /^I am using an asset host$/ do
Middleman::Server.activate :asset_host
Middleman::Server.set :asset_host do |asset|
2010-02-03 02:03:43 +01:00
"http://assets%d.example.com" % (asset.hash % 4)
end
@browser = Rack::Test::Session.new(Rack::MockSession.new(Middleman::Server.new))
2010-02-03 02:03:43 +01:00
end