2009-11-23 00:37:11 +01:00
|
|
|
Given /^page "([^\"]*)" has layout "([^\"]*)"$/ do |url, layout|
|
2011-07-24 07:49:32 +02:00
|
|
|
@server ||= Middleman.server
|
|
|
|
@server.set :root, File.join(File.dirname(File.dirname(File.dirname(__FILE__))), "fixtures", "test-app")
|
|
|
|
@server.page(url, :layout => layout.to_sym)
|
2009-11-23 00:37:11 +01:00
|
|
|
end
|
|
|
|
|
|
|
|
Given /^"([^\"]*)" with_layout block has layout "([^\"]*)"$/ do |url, layout|
|
2011-07-24 07:49:32 +02:00
|
|
|
@server ||= Middleman.server
|
|
|
|
@server.set :root, File.join(File.dirname(File.dirname(File.dirname(__FILE__))), "fixtures", "test-app")
|
|
|
|
@server.with_layout(layout.to_sym) do
|
|
|
|
page(url)
|
2009-11-23 00:37:11 +01:00
|
|
|
end
|
|
|
|
end
|