rails_tasks 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 00daa03ac96e433238288919d6249d969b5472f7
4
- data.tar.gz: 03edaa527c6f8afe971262600e6cd723e6a2462f
3
+ metadata.gz: 1a3ae61d545a2e4fdf009b78c7ebd8f9dc3d589f
4
+ data.tar.gz: 2799522212c4b411c7dd656ba7875ade48f143c3
5
5
  SHA512:
6
- metadata.gz: a6669a41390952f722e22f9d45e2a7f2f3dc08e393bc39eaadb8b79ce2b12d2a91f5ac5bb0e61cb1fd3e715cfb4cf4e63f551aad1fa315cadcd82fecdc11ff01
7
- data.tar.gz: e6341ec11e504692f752c06e77c1e093feb446461186219f80e0c7dc8ffca1f7b41064c3dcee9b8c5d4c0311f3cb2ba94419fb3d51bd1e27f694f7cd676c7e71
6
+ metadata.gz: 8a662a381dd47c07569ecdb8325376dd3e01fb9863b957d79a7918f82201be6c50e084c2400ad41008b21290714882fcedec6069e33cd7ef01f6bf52dd58f84a
7
+ data.tar.gz: 6e12f38784489760c73895db4ee0b3b754c140141cdb532bd72af186c69f9e83a55d37018fc092a6a02eebdfef61791b68e6135302899c6ee77125f4d844b8de
data/lib/rails_tasks.rb CHANGED
@@ -10,11 +10,7 @@ module RailsTasks
10
10
  const_name = "#{controller.to_s.camelize}Controller"
11
11
  controller = ActiveSupport::Dependencies.constantize(const_name)
12
12
 
13
- new_env = env.dup
14
- new_env["action_dispatch.request.path_parameters"] ||= {}
15
- new_env["rack.input"] ||= Rack::RewindableInput.new($stdin)
16
- new_env["REQUEST_METHOD"] ||= 'GET'
17
-
13
+ new_env = request.env.dup
18
14
  new_env["action_dispatch.request.path_parameters"].merge! options
19
15
 
20
16
  s, h, r = controller.action(options[:action]).call(new_env)
@@ -1,3 +1,3 @@
1
1
  module RailsTasks
2
- VERSION = "0.0.1"
2
+ VERSION = "0.0.2"
3
3
  end
@@ -194,5 +194,69 @@ Completed 200 OK in 15ms (Views: 14.7ms | ActiveRecord: 0.0ms)
194
194
   (0.1ms) begin transaction
195
195
  --------------------------
196
196
  RailsTasksTest: test_truth
197
+ --------------------------
198
+  (0.1ms) rollback transaction
199
+  (0.6ms) begin transaction
200
+ -----------------------------------------
201
+ InnerControllerTest: test_should_get_show
202
+ -----------------------------------------
203
+ Processing by InnerController#show as HTML
204
+ Rendered inner/show.html.erb within layouts/inner (1.4ms)
205
+ Completed 200 OK in 39ms (Views: 39.0ms | ActiveRecord: 0.0ms)
206
+  (0.1ms) rollback transaction
207
+  (0.1ms) begin transaction
208
+ -----------------------------------------
209
+ OuterControllerTest: test_should_get_show
210
+ -----------------------------------------
211
+ Processing by OuterController#show as HTML
212
+ Processing by InnerController#show as HTML
213
+ Completed 200 OK in 1ms (Views: 0.4ms | ActiveRecord: 0.0ms)
214
+ Completed 200 OK in 32ms (Views: 31.6ms | ActiveRecord: 0.0ms)
215
+  (0.1ms) rollback transaction
216
+  (0.1ms) begin transaction
217
+ --------------------------
218
+ RailsTasksTest: test_truth
219
+ --------------------------
220
+  (0.1ms) rollback transaction
221
+  (0.4ms) begin transaction
222
+ -----------------------------------------
223
+ InnerControllerTest: test_should_get_show
224
+ -----------------------------------------
225
+ Processing by InnerController#show as HTML
226
+ Rendered inner/show.html.erb within layouts/inner (1.0ms)
227
+ Completed 200 OK in 6ms (Views: 5.5ms | ActiveRecord: 0.0ms)
228
+  (0.1ms) rollback transaction
229
+  (0.1ms) begin transaction
230
+ -----------------------------------------
231
+ OuterControllerTest: test_should_get_show
232
+ -----------------------------------------
233
+ Processing by OuterController#show as HTML
234
+ Completed 500 Internal Server Error in 20ms
235
+  (0.1ms) rollback transaction
236
+  (0.2ms) begin transaction
237
+ --------------------------
238
+ RailsTasksTest: test_truth
239
+ --------------------------
240
+  (0.1ms) rollback transaction
241
+  (0.4ms) begin transaction
242
+ -----------------------------------------
243
+ InnerControllerTest: test_should_get_show
244
+ -----------------------------------------
245
+ Processing by InnerController#show as HTML
246
+ Rendered inner/show.html.erb within layouts/inner (0.9ms)
247
+ Completed 200 OK in 6ms (Views: 5.4ms | ActiveRecord: 0.0ms)
248
+  (0.1ms) rollback transaction
249
+  (0.1ms) begin transaction
250
+ -----------------------------------------
251
+ OuterControllerTest: test_should_get_show
252
+ -----------------------------------------
253
+ Processing by OuterController#show as HTML
254
+ Processing by InnerController#show as HTML
255
+ Completed 200 OK in 1ms (Views: 0.4ms | ActiveRecord: 0.0ms)
256
+ Completed 200 OK in 15ms (Views: 14.9ms | ActiveRecord: 0.0ms)
257
+  (0.2ms) rollback transaction
258
+  (0.1ms) begin transaction
259
+ --------------------------
260
+ RailsTasksTest: test_truth
197
261
  --------------------------
198
262
   (0.1ms) rollback transaction
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rails_tasks
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ivgeni Slabkovski