Hi *, I'm trying to use subdomains on Rails 3, but haven't been able to test 
the behaviour:      

   it "routes 'http://test.example.com/dashboard' to UsersController#show with 
subdomain 'test'" do
    { :get => 'http://test.example.com/dashboard' }.should route_to(
      :controller => 'users', :action => 'show', :subdomain => 'test' )
  end

My route is:

constraints( :subdomain => /.+/ ) do
  match '/dashboard' => 'users#show'
end

The test fails like this:

   The recognized options <{"action"=>"show", "controller"=>"users"}> did not 
match <{"action"=>"show", "subdomain"=>"test", "controller"=>"users"}>, 
difference: <{"subdomain"=>"test"}>

I found many references to this syntax and usage on Google, but even from 
console the subdomain is only in the request object.
Someone managed to do something like this and can share ?
I've also tried to use subdomain-fu, but no success so far

ngw

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to