Skip to content

Instantly share code, notes, and snippets.

@franzejr
Created June 21, 2012 02:00
Show Gist options
  • Save franzejr/2963422 to your computer and use it in GitHub Desktop.
Save franzejr/2963422 to your computer and use it in GitHub Desktop.
Routing Test with Rspec
# encoding: UTF-8
require 'spec_helper'
describe OccurrencesController do
context "Show Occurrence" do
it "show one occurence" do
{ :get => "/events/1/tracks/2/occurrences/3/" }.
should route_to(
:controller => "occurrences",
:action => "show",
:event_id => "1",
:track_id => "2",
:id => "3"
)
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment