public
Rubygem
Description: RSpec extension library for Ruby on Rails
Homepage:
Clone URL: git://github.com/dchelimsky/rspec-rails.git
Generated route specs have shorter names, making it less painful to modify their 
implementation
aslakhellesoy (author)
Fri Aug 01 02:18:13 -0700 2008
commit  732577a9326841a9c933b3b8d2479f9ef1fc2570
tree    eebf50d6a8077ed1d73bbfe2a5687bb6fcf9c409
parent  fff41e5a9bc3c684da1b43786952b9c50e4a0b35
...
6
7
8
 
9
10
11
...
6
7
8
9
10
11
12
0
@@ -6,6 +6,7 @@ so the autotest executable won't automatically load rspec anymore. This allows
0
 rspec to live side by side other spec frameworks without always co-opting
0
 autotest through autotest's discovery mechanism.
0
 
0
+* Generated route specs have shorter names, making it less painful to modify their implementation
0
 * Add conditional so Rails 2.1.0 doesn't warn about cache_template_extensions (patch from James Herdman)
0
 * Fixed stub_model examples to work with Rails 2.1.0 (the code was fine, just the examples needed patching)
0
 * use hoe for build/release
...
2
3
4
5
6
 
7
8
9
10
 
11
12
13
14
 
15
16
17
18
 
19
20
21
22
 
23
24
25
26
 
27
28
29
30
31
32
33
 
34
35
36
37
 
38
39
40
41
 
42
43
44
45
 
46
47
48
49
 
50
51
52
53
 
54
55
56
57
 
58
59
60
...
2
3
4
 
 
5
6
7
8
 
9
10
11
12
 
13
14
15
16
 
17
18
19
20
 
21
22
23
24
 
25
26
27
28
29
30
 
 
31
32
33
34
 
35
36
37
38
 
39
40
41
42
 
43
44
45
46
 
47
48
49
50
 
51
52
53
54
 
55
56
57
58
0
@@ -2,59 +2,57 @@ require File.expand_path(File.dirname(__FILE__) + '<%= '/..' * class_nesting_dep
0
 
0
 describe <%= controller_class_name %>Controller do
0
   describe "route generation" do
0
-
0
-    it "should map { :controller => '<%= table_name %>', :action => 'index' } to /<%= table_name %>" do
0
+    it "should map #index" do
0
       route_for(:controller => "<%= table_name %>", :action => "index").should == "/<%= table_name %>"
0
     end
0
   
0
-    it "should map { :controller => '<%= table_name %>', :action => 'new' } to /<%= table_name %>/new" do
0
+    it "should map #new" do
0
       route_for(:controller => "<%= table_name %>", :action => "new").should == "/<%= table_name %>/new"
0
     end
0
   
0
-    it "should map { :controller => '<%= table_name %>', :action => 'show', :id => 1 } to /<%= table_name %>/1" do
0
+    it "should map #show" do
0
       route_for(:controller => "<%= table_name %>", :action => "show", :id => 1).should == "/<%= table_name %>/1"
0
     end
0
   
0
-    it "should map { :controller => '<%= table_name %>', :action => 'edit', :id => 1 } to /<%= table_name %>/1<%= resource_edit_path %>" do
0
+    it "should map #edit" do
0
       route_for(:controller => "<%= table_name %>", :action => "edit", :id => 1).should == "/<%= table_name %>/1<%= resource_edit_path %>"
0
     end
0
   
0
-    it "should map { :controller => '<%= table_name %>', :action => 'update', :id => 1} to /<%= table_name %>/1" do
0
+    it "should map #update" do
0
       route_for(:controller => "<%= table_name %>", :action => "update", :id => 1).should == "/<%= table_name %>/1"
0
     end
0
   
0
-    it "should map { :controller => '<%= table_name %>', :action => 'destroy', :id => 1} to /<%= table_name %>/1" do
0
+    it "should map #destroy" do
0
       route_for(:controller => "<%= table_name %>", :action => "destroy", :id => 1).should == "/<%= table_name %>/1"
0
     end
0
   end
0
 
0
   describe "route recognition" do
0
-
0
-    it "should generate params { :controller => '<%= table_name %>', action => 'index' } from GET /<%= table_name %>" do
0
+    it "should generate params for #index" do
0
       params_from(:get, "/<%= table_name %>").should == {:controller => "<%= table_name %>", :action => "index"}
0
     end
0
   
0
-    it "should generate params { :controller => '<%= table_name %>', action => 'new' } from GET /<%= table_name %>/new" do
0
+    it "should generate params for #new" do
0
       params_from(:get, "/<%= table_name %>/new").should == {:controller => "<%= table_name %>", :action => "new"}
0
     end
0
   
0
-    it "should generate params { :controller => '<%= table_name %>', action => 'create' } from POST /<%= table_name %>" do
0
+    it "should generate params for #create" do
0
       params_from(:post, "/<%= table_name %>").should == {:controller => "<%= table_name %>", :action => "create"}
0
     end
0
   
0
-    it "should generate params { :controller => '<%= table_name %>', action => 'show', id => '1' } from GET /<%= table_name %>/1" do
0
+    it "should generate params for #show" do
0
       params_from(:get, "/<%= table_name %>/1").should == {:controller => "<%= table_name %>", :action => "show", :id => "1"}
0
     end
0
   
0
-    it "should generate params { :controller => '<%= table_name %>', action => 'edit', id => '1' } from GET /<%= table_name %>/1;edit" do
0
+    it "should generate params for #edit" do
0
       params_from(:get, "/<%= table_name %>/1<%= resource_edit_path %>").should == {:controller => "<%= table_name %>", :action => "edit", :id => "1"}
0
     end
0
   
0
-    it "should generate params { :controller => '<%= table_name %>', action => 'update', id => '1' } from PUT /<%= table_name %>/1" do
0
+    it "should generate params for #update" do
0
       params_from(:put, "/<%= table_name %>/1").should == {:controller => "<%= table_name %>", :action => "update", :id => "1"}
0
     end
0
   
0
-    it "should generate params { :controller => '<%= table_name %>', action => 'destroy', id => '1' } from DELETE /<%= table_name %>/1" do
0
+    it "should generate params for #destroy" do
0
       params_from(:delete, "/<%= table_name %>/1").should == {:controller => "<%= table_name %>", :action => "destroy", :id => "1"}
0
     end
0
   end

Comments