diff options
| author | Marc Florisson | 2015-02-03 12:26:37 +0100 |
|---|---|---|
| committer | Marc Florisson | 2015-02-03 12:26:37 +0100 |
| commit | a98cf1bdae71922512abb284429c96777d01db18 (patch) | |
| tree | e9f76cfa66b50e48b9061a1d3b3e34022e9e87a2 /spec/routing/time_tables_spec.rb | |
| parent | 04148815395986714ac6c1f98abcc23744cb97eb (diff) | |
| download | chouette-core-a98cf1bdae71922512abb284429c96777d01db18.tar.bz2 | |
first refactor to add rule parameter set to organisation
Diffstat (limited to 'spec/routing/time_tables_spec.rb')
| -rw-r--r-- | spec/routing/time_tables_spec.rb | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/spec/routing/time_tables_spec.rb b/spec/routing/time_tables_spec.rb new file mode 100644 index 000000000..45e426f4c --- /dev/null +++ b/spec/routing/time_tables_spec.rb @@ -0,0 +1,31 @@ +require 'spec_helper' + +describe TimeTablesController do + describe "routing" do + it "not recognize #routes" do + get( "/referentials/1/time_tables/2/routes").should_not route_to( + :controller => "time_tables", :action => "routes", + :referential_id => "1", :id => "2" + ) + end + it "not recognize #lines" do + get( "/referentials/1/time_tables/2/lines").should_not route_to( + :controller => "time_tables", :action => "lines", + :referential_id => "1", :id => "2" + ) + end + it "not recognize #time_table_periods" do + get( "/referentials/1/time_tables/2/time_table_periods").should_not route_to( + "time_table_periods#index", + :referential_id => "1", :time_table_id => "2" + ) + end + it "recognize and generate #show" do + get( "/referentials/1/time_tables/2").should route_to( + :controller => "time_tables", :action => "show", + :referential_id => "1", :id => "2" + ) + end + end +end + |
