irt 1.2.8 → 1.2.9
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/lib/irt/helpers/rails.rb +31 -0
- data/lib/irt.rb +5 -1
- metadata +2 -1
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.2.
|
1
|
+
1.2.9
|
@@ -0,0 +1,31 @@
|
|
1
|
+
module IRT
|
2
|
+
module Helpers
|
3
|
+
module Rails
|
4
|
+
|
5
|
+
def post(*args)
|
6
|
+
data = args.pop
|
7
|
+
app.post path(*args), data
|
8
|
+
end
|
9
|
+
|
10
|
+
def get(*args)
|
11
|
+
app.get path(*args)
|
12
|
+
end
|
13
|
+
|
14
|
+
def delete(*args)
|
15
|
+
app.delete path(*args)
|
16
|
+
end
|
17
|
+
|
18
|
+
def path(*args)
|
19
|
+
path = args.shift
|
20
|
+
app.send("#{path}_path", *args)
|
21
|
+
end
|
22
|
+
|
23
|
+
def response
|
24
|
+
app.response.body
|
25
|
+
end
|
26
|
+
|
27
|
+
|
28
|
+
|
29
|
+
end
|
30
|
+
end
|
31
|
+
end
|
data/lib/irt.rb
CHANGED
@@ -160,6 +160,10 @@ require 'irt/extensions/kernel'
|
|
160
160
|
require 'irt/extensions/object'
|
161
161
|
require 'irt/extensions/method'
|
162
162
|
require 'irt/prompter'
|
163
|
-
|
163
|
+
if defined?(ActiveSupport::BufferedLogger)
|
164
|
+
require 'irt/extensions/rails'
|
165
|
+
require 'irt/helpers/rails'
|
166
|
+
end
|
167
|
+
|
164
168
|
|
165
169
|
end
|
metadata
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
name: irt
|
3
3
|
version: !ruby/object:Gem::Version
|
4
4
|
prerelease:
|
5
|
-
version: 1.2.
|
5
|
+
version: 1.2.9
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- Domizio Demichelis
|
@@ -87,6 +87,7 @@ files:
|
|
87
87
|
- lib/irt/extensions/method.rb
|
88
88
|
- lib/irt/extensions/object.rb
|
89
89
|
- lib/irt/extensions/rails.rb
|
90
|
+
- lib/irt/helpers/rails.rb
|
90
91
|
- lib/irt/history.rb
|
91
92
|
- lib/irt/hunks.rb
|
92
93
|
- lib/irt/init.rb
|