routespec 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (177) hide show
  1. data/README.txt +66 -0
  2. data/Rakefile +26 -0
  3. data/bin/routespec +29 -0
  4. data/lib/routespec.rb +22 -0
  5. data/lib/routespec/builder.rb +111 -0
  6. data/lib/routespec/dyr.rb +50 -0
  7. data/lib/routespec/fyle.rb +72 -0
  8. data/lib/routespec/parser.rb +143 -0
  9. data/lib/routespec/railtie.rb +7 -0
  10. data/lib/routespec/routespec/requests/.gitkeep +0 -0
  11. data/lib/routespec/routespec/support/.gitkeep +0 -0
  12. data/lib/routespec/routespec/templates/default_spec.erb +24 -0
  13. data/lib/routespec/tasks.rb +18 -0
  14. data/lib/routespec/tasks/routespec.rake +22 -0
  15. data/lib/routespec/template_vars.rb +7 -0
  16. data/lib/routespec/version.rb +3 -0
  17. data/test/files/awesome.yml +1 -0
  18. data/test/files/response_code_vcr_spec.erb +24 -0
  19. data/test/files/routes.txt +12 -0
  20. data/test/files/routes.yml +193 -0
  21. data/test/files/routes_hash.rb +159 -0
  22. data/test/files/routes_hash_2.rb +153 -0
  23. data/test/files/routes_hash_3.rb +1 -0
  24. data/test/files/tasks_routes.txt +21 -0
  25. data/test/files/template_spec.erb +13 -0
  26. data/test/files/unclean.txt +11 -0
  27. data/test/rails311/Gemfile +4 -0
  28. data/test/rails311/Gemfile.lock +90 -0
  29. data/test/rails311/README +261 -0
  30. data/test/rails311/Rakefile +7 -0
  31. data/test/rails311/app/assets/images/rails.png +0 -0
  32. data/test/rails311/app/assets/javascripts/application.js +9 -0
  33. data/test/rails311/app/assets/javascripts/beers.js +2 -0
  34. data/test/rails311/app/assets/javascripts/chips.js +2 -0
  35. data/test/rails311/app/assets/javascripts/sports.js +2 -0
  36. data/test/rails311/app/assets/stylesheets/application.css +7 -0
  37. data/test/rails311/app/assets/stylesheets/beers.css +4 -0
  38. data/test/rails311/app/assets/stylesheets/chips.css +4 -0
  39. data/test/rails311/app/assets/stylesheets/scaffold.css +56 -0
  40. data/test/rails311/app/assets/stylesheets/sports.css +4 -0
  41. data/test/rails311/app/controllers/application_controller.rb +3 -0
  42. data/test/rails311/app/controllers/beers_controller.rb +83 -0
  43. data/test/rails311/app/controllers/chips_controller.rb +83 -0
  44. data/test/rails311/app/controllers/sports_controller.rb +83 -0
  45. data/test/rails311/app/helpers/application_helper.rb +2 -0
  46. data/test/rails311/app/helpers/beers_helper.rb +2 -0
  47. data/test/rails311/app/helpers/chips_helper.rb +2 -0
  48. data/test/rails311/app/helpers/sports_helper.rb +2 -0
  49. data/test/rails311/app/models/beer.rb +2 -0
  50. data/test/rails311/app/models/chip.rb +2 -0
  51. data/test/rails311/app/models/sport.rb +2 -0
  52. data/test/rails311/app/views/beers/_form.html.erb +17 -0
  53. data/test/rails311/app/views/beers/edit.html.erb +6 -0
  54. data/test/rails311/app/views/beers/index.html.erb +21 -0
  55. data/test/rails311/app/views/beers/new.html.erb +5 -0
  56. data/test/rails311/app/views/beers/show.html.erb +5 -0
  57. data/test/rails311/app/views/chips/_form.html.erb +17 -0
  58. data/test/rails311/app/views/chips/edit.html.erb +6 -0
  59. data/test/rails311/app/views/chips/index.html.erb +21 -0
  60. data/test/rails311/app/views/chips/new.html.erb +5 -0
  61. data/test/rails311/app/views/chips/show.html.erb +5 -0
  62. data/test/rails311/app/views/layouts/application.html.erb +14 -0
  63. data/test/rails311/app/views/sports/_form.html.erb +17 -0
  64. data/test/rails311/app/views/sports/edit.html.erb +6 -0
  65. data/test/rails311/app/views/sports/index.html.erb +21 -0
  66. data/test/rails311/app/views/sports/new.html.erb +5 -0
  67. data/test/rails311/app/views/sports/show.html.erb +5 -0
  68. data/test/rails311/config.ru +4 -0
  69. data/test/rails311/config/application.rb +48 -0
  70. data/test/rails311/config/boot.rb +6 -0
  71. data/test/rails311/config/database.yml +25 -0
  72. data/test/rails311/config/environment.rb +5 -0
  73. data/test/rails311/config/environments/development.rb +30 -0
  74. data/test/rails311/config/environments/production.rb +60 -0
  75. data/test/rails311/config/environments/test.rb +39 -0
  76. data/test/rails311/config/initializers/backtrace_silencers.rb +7 -0
  77. data/test/rails311/config/initializers/inflections.rb +10 -0
  78. data/test/rails311/config/initializers/mime_types.rb +5 -0
  79. data/test/rails311/config/initializers/secret_token.rb +7 -0
  80. data/test/rails311/config/initializers/session_store.rb +8 -0
  81. data/test/rails311/config/initializers/wrap_parameters.rb +14 -0
  82. data/test/rails311/config/locales/en.yml +5 -0
  83. data/test/rails311/config/routes.rb +64 -0
  84. data/test/rails311/db/development.sqlite3 +0 -0
  85. data/test/rails311/db/migrate/20111227222038_create_beers.rb +8 -0
  86. data/test/rails311/db/migrate/20111227222056_create_chips.rb +8 -0
  87. data/test/rails311/db/migrate/20111227222113_create_sports.rb +8 -0
  88. data/test/rails311/db/schema.rb +31 -0
  89. data/test/rails311/db/seeds.rb +7 -0
  90. data/test/rails311/db/test.sqlite3 +0 -0
  91. data/test/rails311/doc/README_FOR_APP +2 -0
  92. data/test/rails311/log/development.log +28 -0
  93. data/test/rails311/log/test.log +0 -0
  94. data/test/rails311/public/404.html +26 -0
  95. data/test/rails311/public/422.html +26 -0
  96. data/test/rails311/public/500.html +26 -0
  97. data/test/rails311/public/favicon.ico +0 -0
  98. data/test/rails311/public/index.html +241 -0
  99. data/test/rails311/public/robots.txt +5 -0
  100. data/test/rails311/script/rails +6 -0
  101. data/test/rails311/spec/routespec/requests/beers/beers_spec.rb +74 -0
  102. data/test/rails311/spec/routespec/requests/chips/chips_spec.rb +74 -0
  103. data/test/rails311/spec/routespec/requests/sports/sports_spec.rb +74 -0
  104. data/test/rails311/spec/routespec/support/routes.txt +21 -0
  105. data/test/rails311/spec/routespec/support/routes.yml +322 -0
  106. data/test/rails311/spec/routespec/templates/default_spec.erb +24 -0
  107. data/test/rails311/test/fixtures/beers.yml +11 -0
  108. data/test/rails311/test/fixtures/chips.yml +11 -0
  109. data/test/rails311/test/fixtures/sports.yml +11 -0
  110. data/test/rails311/test/functional/beers_controller_test.rb +49 -0
  111. data/test/rails311/test/functional/chips_controller_test.rb +49 -0
  112. data/test/rails311/test/functional/sports_controller_test.rb +49 -0
  113. data/test/rails311/test/performance/browsing_test.rb +12 -0
  114. data/test/rails311/test/test_helper.rb +13 -0
  115. data/test/rails311/test/unit/beer_test.rb +7 -0
  116. data/test/rails311/test/unit/chip_test.rb +7 -0
  117. data/test/rails311/test/unit/helpers/beers_helper_test.rb +4 -0
  118. data/test/rails311/test/unit/helpers/chips_helper_test.rb +4 -0
  119. data/test/rails311/test/unit/helpers/sports_helper_test.rb +4 -0
  120. data/test/rails311/test/unit/sport_test.rb +7 -0
  121. data/test/rails311/vendor/cache/actionmailer-3.1.1.gem +0 -0
  122. data/test/rails311/vendor/cache/actionpack-3.1.1.gem +0 -0
  123. data/test/rails311/vendor/cache/activemodel-3.1.1.gem +0 -0
  124. data/test/rails311/vendor/cache/activerecord-3.1.1.gem +0 -0
  125. data/test/rails311/vendor/cache/activeresource-3.1.1.gem +0 -0
  126. data/test/rails311/vendor/cache/activesupport-3.1.1.gem +0 -0
  127. data/test/rails311/vendor/cache/arel-2.2.1.gem +0 -0
  128. data/test/rails311/vendor/cache/builder-3.0.0.gem +0 -0
  129. data/test/rails311/vendor/cache/erubis-2.7.0.gem +0 -0
  130. data/test/rails311/vendor/cache/hike-1.2.1.gem +0 -0
  131. data/test/rails311/vendor/cache/i18n-0.6.0.gem +0 -0
  132. data/test/rails311/vendor/cache/json-1.6.4.gem +0 -0
  133. data/test/rails311/vendor/cache/mail-2.3.0.gem +0 -0
  134. data/test/rails311/vendor/cache/mime-types-1.17.2.gem +0 -0
  135. data/test/rails311/vendor/cache/multi_json-1.0.4.gem +0 -0
  136. data/test/rails311/vendor/cache/polyglot-0.3.3.gem +0 -0
  137. data/test/rails311/vendor/cache/rack-1.3.5.gem +0 -0
  138. data/test/rails311/vendor/cache/rack-cache-1.1.gem +0 -0
  139. data/test/rails311/vendor/cache/rack-mount-0.8.3.gem +0 -0
  140. data/test/rails311/vendor/cache/rack-ssl-1.3.2.gem +0 -0
  141. data/test/rails311/vendor/cache/rack-test-0.6.1.gem +0 -0
  142. data/test/rails311/vendor/cache/rails-3.1.1.gem +0 -0
  143. data/test/rails311/vendor/cache/railties-3.1.1.gem +0 -0
  144. data/test/rails311/vendor/cache/rake-0.9.2.2.gem +0 -0
  145. data/test/rails311/vendor/cache/rdoc-3.12.gem +0 -0
  146. data/test/rails311/vendor/cache/sprockets-2.0.3.gem +0 -0
  147. data/test/rails311/vendor/cache/sqlite3-1.3.5.gem +0 -0
  148. data/test/rails311/vendor/cache/thor-0.14.6.gem +0 -0
  149. data/test/rails311/vendor/cache/tilt-1.3.3.gem +0 -0
  150. data/test/rails311/vendor/cache/treetop-1.4.10.gem +0 -0
  151. data/test/rails311/vendor/cache/tzinfo-0.3.31.gem +0 -0
  152. data/test/sandbox/awsome.txt +1 -0
  153. data/test/sandbox/cerveja/muito_legal/cool/cool_spec.rb +1 -0
  154. data/test/sandbox/cerveja/rad/rad_spec.rb +1 -0
  155. data/test/sandbox/cool.txt +4 -0
  156. data/test/sandbox/rails_root/routespec/templates/default_spec.erb +24 -0
  157. data/test/sandbox/requests/dynamic/dynamic_spec.rb +17 -0
  158. data/test/sandbox/requests/errors/errors_spec.rb +36 -0
  159. data/test/sandbox/requests/info_panel/info_panel_spec.rb +16 -0
  160. data/test/sandbox/requests/legacy/legacy_spec.rb +26 -0
  161. data/test/sandbox/requests2/dynamic/dynamic_spec.rb +17 -0
  162. data/test/sandbox/requests2/errors/errors_spec.rb +36 -0
  163. data/test/sandbox/requests2/info_panel/info_panel_spec.rb +16 -0
  164. data/test/sandbox/requests2/legacy/legacy_spec.rb +26 -0
  165. data/test/sandbox/routes.txt +21 -0
  166. data/test/sandbox/routes.yml +193 -0
  167. data/test/sandbox/seu_jorge.yml +3 -0
  168. data/test/test_builder.rb +118 -0
  169. data/test/test_config.rb +5 -0
  170. data/test/test_dyr.rb +56 -0
  171. data/test/test_fyle.rb +59 -0
  172. data/test/test_parser.rb +84 -0
  173. data/test/test_rails311.rb +15 -0
  174. data/test/test_routespec.rb +8 -0
  175. data/test/test_tasks.rb +26 -0
  176. data/test/test_template_vars.rb +18 -0
  177. metadata +382 -0
@@ -0,0 +1,7 @@
1
+ module Routespec
2
+ class Railtie < Rails::Railtie
3
+ rake_tasks do
4
+ load "#{File.dirname(__FILE__)}/tasks/routespec.rake"
5
+ end
6
+ end
7
+ end
File without changes
File without changes
@@ -0,0 +1,24 @@
1
+ require "spec_helper"
2
+
3
+ #
4
+ # routes
5
+ <% @routes.each do |route| %>
6
+ # <%= route.raw %>
7
+ <% end %>
8
+ #
9
+ describe "<%= @name %> response status codes" do
10
+ <% @routes.each do |route| %>
11
+ describe "<%= route.http_verb %> <%= route.path %>" do
12
+ it "should have a response", :vcr do
13
+ <% if route.vars %>
14
+ <% route.vars.each do |var| %>
15
+ <%= var %>
16
+ <% end %>
17
+ <% end %>
18
+ <%= route.http_verb.downcase %> <%= route.helper_path %>
19
+ response.status.should be(<%= route.status_code %>)
20
+ end
21
+ end
22
+
23
+ <% end %>
24
+ end
@@ -0,0 +1,18 @@
1
+ module Routespec
2
+ module Tasks
3
+ class << self
4
+ ##
5
+ # output file should be "#{Rails.root}/spec/routespec/support/routes.txt"
6
+ # pass Rails.root in dir_name arg
7
+ def routes(dir_name, output_file_name)
8
+ output = nil
9
+ Dir.chdir(dir_name) do
10
+ output = `rake routes`
11
+ end
12
+ raise unless Dir.exist?(File.dirname(output_file_name))
13
+ Routespec::Fyle.string_to_file(output, output_file_name)
14
+ return true
15
+ end
16
+ end
17
+ end
18
+ end
@@ -0,0 +1,22 @@
1
+ namespace :routespec do
2
+ desc "\"$ rake routes\" output to Rails.root/spec/routespec/rake_routes.txt; Target specific controller with CONTROLLER=x."
3
+ task :routes do
4
+ output_file_name = "#{Rails.root}/spec/routespec/support/routes.txt"
5
+ Routespec::Tasks.routes(Rails.root, output_file_name)
6
+ end
7
+
8
+ desc "rake_routes.txt parsed to hash with output to Rails.root/spec/routespec/support/rake_routes.yml"
9
+ task :text_to_yaml do
10
+ input_file_name = "#{Rails.root}/spec/routespec/support/routes.txt"
11
+ output_file_name = "#{Rails.root}/spec/routespec/support/routes.yml"
12
+ Routespec::Builder.text_to_yaml(input_file_name, output_file_name)
13
+ end
14
+
15
+ desc "rake_routes.yml used to create tests in Rails.root/spec/routspec/requests/ with test-template Rails.root/spec/routespec/templates/example_template.erb"
16
+ task :build_tests do
17
+ input_file_name = "#{Rails.root}/spec/routespec/support/routes.yml"
18
+ template_file_name = "#{Rails.root}/spec/routespec/templates/default_spec.erb"
19
+ output_dir_name = "#{Rails.root}/spec/routespec/requests"
20
+ Routespec::Builder.yaml_to_specs(input_file_name, template_file_name, output_dir_name)
21
+ end
22
+ end
@@ -0,0 +1,7 @@
1
+ module Routespec
2
+ class TemplateVars
3
+ def get_binding
4
+ binding
5
+ end
6
+ end
7
+ end
@@ -0,0 +1,3 @@
1
+ module Routespec
2
+ VERSION = "0.0.1"
3
+ end
@@ -0,0 +1 @@
1
+ :awesome: beer
@@ -0,0 +1,24 @@
1
+ require "spec_helper"
2
+
3
+ #
4
+ # routes
5
+ <% @routes.each do |route| %>
6
+ # <%= route.raw %>
7
+ <% end %>
8
+ #
9
+ describe "<%= @name %> response status codes" do
10
+ <% @routes.each do |route| %>
11
+ describe "<%= route.http_verb %> <%= route.path %>" do
12
+ it "should have a response", :vcr do
13
+ <% if route.vars %>
14
+ <% route.vars.each do |var| %>
15
+ <%= var %>
16
+ <% end %>
17
+ <% end %>
18
+ <%= route.http_verb.downcase %> <%= route.helper_path %>
19
+ response.status.should be(<%= route.status_code %>)
20
+ end
21
+ end
22
+
23
+ <% end %>
24
+ end
@@ -0,0 +1,12 @@
1
+ dynamic_controller /:controller/render_event_response(.:format) {:action=>"render_event_response"}
2
+ no_controller /render_event_response(.:format) {:action=>"render_event_response"}
3
+ info_panel_edit GET /info_panel/edit(.:format) {:controller=>"info_panel", :action=>"edit"}
4
+ POST /errors(.:format) {:action=>"create", :controller=>"errors"}
5
+ PUT /errors/:id(.:format) {:action=>"update", :controller=>"errors"}
6
+ DELETE /errors/:id(.:format) {:action=>"destroy", :controller=>"errors"}
7
+ /index.cfm(.:format) {:controller=>"legacy", :action=>"index"}
8
+ /listingid=:id(.:format) {:id=>/[0-9]+/, :controller=>"legacy", :action=>"listingid"}
9
+ /mls/:id(.:format) {:controller=>"agents_and_offices/listings", :action=>"mls"}
10
+ agent_listing_enquiries POST /agents/:agent_id/listings/:listing_id/enquiries(.:format) {:action=>"create", :controller=>"agents_and_offices/enquiries"}
11
+ new_agent_listing_enquiry GET /agents/:agent_id/listings/:listing_id/enquiries/new(.:format) {:action=>"new", :controller=>"agents_and_offices/enquiries"}
12
+ agent_listing_gallery_photo GET /agents/:agent_id/listings/:listing_id/galleries/:gallery_id/photos/:id(.:format) {:action=>"show", :controller=>"agents_and_offices/photos"}
@@ -0,0 +1,193 @@
1
+ ---
2
+ :dynamic:
3
+ - :raw: dynamic_controller /:controller/render_event_response(.:format) {:action=>"render_event_response"}
4
+ :helper: dynamic_controller
5
+ :http_verb: GET
6
+ :path: /:controller/render_event_response(.:format)
7
+ :action: render_event_response
8
+ :controller:
9
+ :symbols:
10
+ - controller
11
+ - format
12
+ :address:
13
+ - dynamic
14
+ :status_code: 200
15
+ :helper_path: dynamic_controller_path(:controller => controller, :format => format)
16
+ :vars:
17
+ - controller = "REPLACE"
18
+ - format = nil
19
+ :info_panel:
20
+ - :raw: info_panel_edit GET /info_panel/edit(.:format) {:controller=>"info_panel", :action=>"edit"}
21
+ :helper: info_panel_edit
22
+ :http_verb: GET
23
+ :path: /info_panel/edit(.:format)
24
+ :action: edit
25
+ :controller: info_panel
26
+ :symbols:
27
+ - format
28
+ :address:
29
+ - info_panel
30
+ :status_code: 200
31
+ :helper_path: info_panel_edit_path(:format => format)
32
+ :vars:
33
+ - format = nil
34
+ :errors:
35
+ - :raw: POST /errors(.:format) {:action=>"create", :controller=>"errors"}
36
+ :helper:
37
+ :http_verb: POST
38
+ :path: /errors(.:format)
39
+ :action: create
40
+ :controller: errors
41
+ :symbols:
42
+ - format
43
+ :address:
44
+ - errors
45
+ :status_code: 201
46
+ :helper_path: "\"/errors#{format ? \".\" : nil}#{format}\""
47
+ :vars:
48
+ - format = nil
49
+ - :raw: PUT /errors/:id(.:format) {:action=>"update", :controller=>"errors"}
50
+ :helper:
51
+ :http_verb: PUT
52
+ :path: /errors/:id(.:format)
53
+ :action: update
54
+ :controller: errors
55
+ :symbols:
56
+ - id
57
+ - format
58
+ :address:
59
+ - errors
60
+ :status_code: 200
61
+ :helper_path: "\"/errors/#{id}#{format ? \".\" : nil}#{format}\""
62
+ :vars:
63
+ - id = "REPLACE"
64
+ - format = nil
65
+ - :raw: DELETE /errors/:id(.:format) {:action=>"destroy", :controller=>"errors"}
66
+ :helper:
67
+ :http_verb: DELETE
68
+ :path: /errors/:id(.:format)
69
+ :action: destroy
70
+ :controller: errors
71
+ :symbols:
72
+ - id
73
+ - format
74
+ :address:
75
+ - errors
76
+ :status_code: 200
77
+ :helper_path: "\"/errors/#{id}#{format ? \".\" : nil}#{format}\""
78
+ :vars:
79
+ - id = "REPLACE"
80
+ - format = nil
81
+ :legacy:
82
+ - :raw: /index.cfm(.:format) {:controller=>"legacy", :action=>"index"}
83
+ :helper:
84
+ :http_verb: GET
85
+ :path: /index.cfm(.:format)
86
+ :action: index
87
+ :controller: legacy
88
+ :symbols:
89
+ - format
90
+ :address:
91
+ - legacy
92
+ :status_code: 200
93
+ :helper_path: "\"/index#{format ? \".\" : nil}cfm.#{format}\""
94
+ :vars:
95
+ - format = nil
96
+ - :raw: /listingid=:id(.:format) {:id=>/[0-9]+/, :controller=>"legacy", :action=>"listingid"}
97
+ :helper:
98
+ :http_verb: GET
99
+ :path: /listingid=:id(.:format)
100
+ :action: listingid
101
+ :controller: legacy
102
+ :symbols:
103
+ - id
104
+ - format
105
+ :address:
106
+ - legacy
107
+ :status_code: 200
108
+ :helper_path: "\"/listingid=#{id}#{format ? \".\" : nil}#{format}\""
109
+ :vars:
110
+ - id = "REPLACE"
111
+ - format = nil
112
+ :agents_and_offices:
113
+ :listings:
114
+ - :raw: /mls/:id(.:format) {:controller=>"agents_and_offices/listings", :action=>"mls"}
115
+ :helper:
116
+ :http_verb: GET
117
+ :path: /mls/:id(.:format)
118
+ :action: mls
119
+ :controller: agents_and_offices/listings
120
+ :symbols:
121
+ - id
122
+ - format
123
+ :address:
124
+ - agents_and_offices
125
+ - listings
126
+ :status_code: 200
127
+ :helper_path: "\"/mls/#{id}#{format ? \".\" : nil}#{format}\""
128
+ :vars:
129
+ - id = "REPLACE"
130
+ - format = nil
131
+ :enquiries:
132
+ - :raw: agent_listing_enquiries POST /agents/:agent_id/listings/:listing_id/enquiries(.:format) {:action=>"create", :controller=>"agents_and_offices/enquiries"}
133
+ :helper: agent_listing_enquiries
134
+ :http_verb: POST
135
+ :path: /agents/:agent_id/listings/:listing_id/enquiries(.:format)
136
+ :action: create
137
+ :controller: agents_and_offices/enquiries
138
+ :symbols:
139
+ - agent_id
140
+ - listing_id
141
+ - format
142
+ :address:
143
+ - agents_and_offices
144
+ - enquiries
145
+ :status_code: 201
146
+ :helper_path: agent_listing_enquiries_path(:agent_id => agent_id, :listing_id => listing_id, :format => format)
147
+ :vars:
148
+ - agent_id = "REPLACE"
149
+ - listing_id = "REPLACE"
150
+ - format = nil
151
+ - :raw: new_agent_listing_enquiry GET /agents/:agent_id/listings/:listing_id/enquiries/new(.:format) {:action=>"new", :controller=>"agents_and_offices/enquiries"}
152
+ :helper: new_agent_listing_enquiry
153
+ :http_verb: GET
154
+ :path: /agents/:agent_id/listings/:listing_id/enquiries/new(.:format)
155
+ :action: new
156
+ :controller: agents_and_offices/enquiries
157
+ :symbols:
158
+ - agent_id
159
+ - listing_id
160
+ - format
161
+ :address:
162
+ - agents_and_offices
163
+ - enquiries
164
+ :status_code: 200
165
+ :helper_path: new_agent_listing_enquiry_path(:agent_id => agent_id, :listing_id => listing_id, :format => format)
166
+ :vars:
167
+ - agent_id = "REPLACE"
168
+ - listing_id = "REPLACE"
169
+ - format = nil
170
+ :photos:
171
+ - :raw: agent_listing_gallery_photo GET /agents/:agent_id/listings/:listing_id/galleries/:gallery_id/photos/:id(.:format) {:action=>"show", :controller=>"agents_and_offices/photos"}
172
+ :helper: agent_listing_gallery_photo
173
+ :http_verb: GET
174
+ :path: /agents/:agent_id/listings/:listing_id/galleries/:gallery_id/photos/:id(.:format)
175
+ :action: show
176
+ :controller: agents_and_offices/photos
177
+ :symbols:
178
+ - agent_id
179
+ - listing_id
180
+ - gallery_id
181
+ - id
182
+ - format
183
+ :address:
184
+ - agents_and_offices
185
+ - photos
186
+ :status_code: 200
187
+ :helper_path: agent_listing_gallery_photo_path(:agent_id => agent_id, :listing_id => listing_id, :gallery_id => gallery_id, :id => id, :format => format)
188
+ :vars:
189
+ - agent_id = "REPLACE"
190
+ - listing_id = "REPLACE"
191
+ - gallery_id = "REPLACE"
192
+ - id = "REPLACE"
193
+ - format = nil
@@ -0,0 +1,159 @@
1
+ @routes_hash = {:lines=>
2
+ {1=>
3
+ {:raw=>
4
+ "dynamic_controller /:controller/render_event_response(.:format) {:action=>\"render_event_response\"}",
5
+ :helper=>"dynamic_controller",
6
+ :http_verb=>"GET",
7
+ :path=>"/:controller/render_event_response(.:format)",
8
+ :action=>"render_event_response",
9
+ :controller=>nil,
10
+ :symbols=>["controller", "format"],
11
+ :address=>["dynamic"],
12
+ :status_code=>200,
13
+ :helper_path=>
14
+ "dynamic_controller_path(:controller => controller, :format => format)",
15
+ :vars=>["controller = \"REPLACE\"", "format = nil"]},
16
+ 3=>
17
+ {:raw=>
18
+ "info_panel_edit GET /info_panel/edit(.:format) {:controller=>\"info_panel\", :action=>\"edit\"}",
19
+ :helper=>"info_panel_edit",
20
+ :http_verb=>"GET",
21
+ :path=>"/info_panel/edit(.:format)",
22
+ :action=>"edit",
23
+ :controller=>"info_panel",
24
+ :symbols=>["format"],
25
+ :address=>["info_panel"],
26
+ :status_code=>200,
27
+ :helper_path=>"info_panel_edit_path(:format => format)",
28
+ :vars=>["format = nil"]},
29
+ 4=>
30
+ {:raw=>
31
+ "POST /errors(.:format) {:action=>\"create\", :controller=>\"errors\"}",
32
+ :helper=>nil,
33
+ :http_verb=>"POST",
34
+ :path=>"/errors(.:format)",
35
+ :action=>"create",
36
+ :controller=>"errors",
37
+ :symbols=>["format"],
38
+ :address=>["errors"],
39
+ :status_code=>201,
40
+ :helper_path=>"\"/errors\#{format ? \".\" : nil}\#{format}\"",
41
+ :vars=>["format = nil"]},
42
+ 5=>
43
+ {:raw=>
44
+ "PUT /errors/:id(.:format) {:action=>\"update\", :controller=>\"errors\"}",
45
+ :helper=>nil,
46
+ :http_verb=>"PUT",
47
+ :path=>"/errors/:id(.:format)",
48
+ :action=>"update",
49
+ :controller=>"errors",
50
+ :symbols=>["id", "format"],
51
+ :address=>["errors"],
52
+ :status_code=>200,
53
+ :helper_path=>"\"/errors/\#{id}\#{format ? \".\" : nil}\#{format}\"",
54
+ :vars=>["id = \"REPLACE\"", "format = nil"]},
55
+ 6=>
56
+ {:raw=>
57
+ "DELETE /errors/:id(.:format) {:action=>\"destroy\", :controller=>\"errors\"}",
58
+ :helper=>nil,
59
+ :http_verb=>"DELETE",
60
+ :path=>"/errors/:id(.:format)",
61
+ :action=>"destroy",
62
+ :controller=>"errors",
63
+ :symbols=>["id", "format"],
64
+ :address=>["errors"],
65
+ :status_code=>200,
66
+ :helper_path=>"\"/errors/\#{id}\#{format ? \".\" : nil}\#{format}\"",
67
+ :vars=>["id = \"REPLACE\"", "format = nil"]},
68
+ 7=>
69
+ {:raw=>
70
+ "/index.cfm(.:format) {:controller=>\"legacy\", :action=>\"index\"}",
71
+ :helper=>nil,
72
+ :http_verb=>"GET",
73
+ :path=>"/index.cfm(.:format)",
74
+ :action=>"index",
75
+ :controller=>"legacy",
76
+ :symbols=>["format"],
77
+ :address=>["legacy"],
78
+ :status_code=>200,
79
+ :helper_path=>"\"/index\#{format ? \".\" : nil}cfm.\#{format}\"",
80
+ :vars=>["format = nil"]},
81
+ 8=>
82
+ {:raw=>
83
+ "/listingid=:id(.:format) {:id=>/[0-9]+/, :controller=>\"legacy\", :action=>\"listingid\"}",
84
+ :helper=>nil,
85
+ :http_verb=>"GET",
86
+ :path=>"/listingid=:id(.:format)",
87
+ :action=>"listingid",
88
+ :controller=>"legacy",
89
+ :symbols=>["id", "format"],
90
+ :address=>["legacy"],
91
+ :status_code=>200,
92
+ :helper_path=>"\"/listingid=\#{id}\#{format ? \".\" : nil}\#{format}\"",
93
+ :vars=>["id = \"REPLACE\"", "format = nil"]},
94
+ 9=>
95
+ {:raw=>
96
+ "/mls/:id(.:format) {:controller=>\"agents_and_offices/listings\", :action=>\"mls\"}",
97
+ :helper=>nil,
98
+ :http_verb=>"GET",
99
+ :path=>"/mls/:id(.:format)",
100
+ :action=>"mls",
101
+ :controller=>"agents_and_offices/listings",
102
+ :symbols=>["id", "format"],
103
+ :address=>["agents_and_offices", "listings"],
104
+ :status_code=>200,
105
+ :helper_path=>"\"/mls/\#{id}\#{format ? \".\" : nil}\#{format}\"",
106
+ :vars=>["id = \"REPLACE\"", "format = nil"]},
107
+ 10=>
108
+ {:raw=>
109
+ "agent_listing_enquiries POST /agents/:agent_id/listings/:listing_id/enquiries(.:format) {:action=>\"create\", :controller=>\"agents_and_offices/enquiries\"}",
110
+ :helper=>"agent_listing_enquiries",
111
+ :http_verb=>"POST",
112
+ :path=>"/agents/:agent_id/listings/:listing_id/enquiries(.:format)",
113
+ :action=>"create",
114
+ :controller=>"agents_and_offices/enquiries",
115
+ :symbols=>["agent_id", "listing_id", "format"],
116
+ :address=>["agents_and_offices", "enquiries"],
117
+ :status_code=>201,
118
+ :helper_path=>
119
+ "agent_listing_enquiries_path(:agent_id => agent_id, :listing_id => listing_id, :format => format)",
120
+ :vars=>
121
+ ["agent_id = \"REPLACE\"", "listing_id = \"REPLACE\"", "format = nil"]},
122
+ 11=>
123
+ {:raw=>
124
+ "new_agent_listing_enquiry GET /agents/:agent_id/listings/:listing_id/enquiries/new(.:format) {:action=>\"new\", :controller=>\"agents_and_offices/enquiries\"}",
125
+ :helper=>"new_agent_listing_enquiry",
126
+ :http_verb=>"GET",
127
+ :path=>"/agents/:agent_id/listings/:listing_id/enquiries/new(.:format)",
128
+ :action=>"new",
129
+ :controller=>"agents_and_offices/enquiries",
130
+ :symbols=>["agent_id", "listing_id", "format"],
131
+ :address=>["agents_and_offices", "enquiries"],
132
+ :status_code=>200,
133
+ :helper_path=>
134
+ "new_agent_listing_enquiry_path(:agent_id => agent_id, :listing_id => listing_id, :format => format)",
135
+ :vars=>
136
+ ["agent_id = \"REPLACE\"", "listing_id = \"REPLACE\"", "format = nil"]},
137
+ 12=>
138
+ {:raw=>
139
+ "agent_listing_gallery_photo GET /agents/:agent_id/listings/:listing_id/galleries/:gallery_id/photos/:id(.:format) {:action=>\"show\", :controller=>\"agents_and_offices/photos\"}",
140
+ :helper=>"agent_listing_gallery_photo",
141
+ :http_verb=>"GET",
142
+ :path=>
143
+ "/agents/:agent_id/listings/:listing_id/galleries/:gallery_id/photos/:id(.:format)",
144
+ :action=>"show",
145
+ :controller=>"agents_and_offices/photos",
146
+ :symbols=>["agent_id", "listing_id", "gallery_id", "id", "format"],
147
+ :address=>["agents_and_offices", "photos"],
148
+ :status_code=>200,
149
+ :helper_path=>
150
+ "agent_listing_gallery_photo_path(:agent_id => agent_id, :listing_id => listing_id, :gallery_id => gallery_id, :id => id, :format => format)",
151
+ :vars=>
152
+ ["agent_id = \"REPLACE\"",
153
+ "listing_id = \"REPLACE\"",
154
+ "gallery_id = \"REPLACE\"",
155
+ "id = \"REPLACE\"",
156
+ "format = nil"]}},
157
+ :lines_without_controller=>
158
+ {2=>
159
+ " no_controller /render_event_response(.:format) {:action=>\"render_event_response\"}\n"}}