Skip to content

Instantly share code, notes, and snippets.

@carllerche
Created August 30, 2008 05:45
Show Gist options
  • Save carllerche/8091 to your computer and use it in GitHub Desktop.
Save carllerche/8091 to your computer and use it in GitHub Desktop.
it "should only use the second namespace" do
Merb::Router.prepare do |r|
r.namespace(:foo) do |f|
# --- First
namespace(:bar) do |b|
b.match("/login").to(:controller => "home").name(:login)
end
# --- Second
r.namespace(:bar) do |b|
b.match("/login").to(:controller => "home").name(:login)
end
end
end
url(:bar_login).should == "/bar/login"
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment