draper 0.12.1 → 0.12.2
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG.txt +4 -0
- data/lib/draper/railtie.rb +7 -0
- data/lib/draper/version.rb +1 -1
- metadata +142 -149
data/CHANGELOG.txt
CHANGED
data/lib/draper/railtie.rb
CHANGED
@@ -46,5 +46,12 @@ module Draper
|
|
46
46
|
end
|
47
47
|
end
|
48
48
|
|
49
|
+
console do
|
50
|
+
require 'action_controller/test_case'
|
51
|
+
ApplicationController.new.set_current_view_context
|
52
|
+
Draper::ViewContext.current.controller.request ||= ActionController::TestRequest.new
|
53
|
+
Draper::ViewContext.current.request ||= Draper::ViewContext.current.controller.request
|
54
|
+
Draper::ViewContext.current.params ||= {}
|
55
|
+
end
|
49
56
|
end
|
50
57
|
end
|
data/lib/draper/version.rb
CHANGED
metadata
CHANGED
@@ -1,183 +1,185 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: draper
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.12.2
|
5
5
|
prerelease:
|
6
|
-
segments:
|
7
|
-
- 0
|
8
|
-
- 12
|
9
|
-
- 1
|
10
|
-
version: 0.12.1
|
11
6
|
platform: ruby
|
12
|
-
authors:
|
7
|
+
authors:
|
13
8
|
- Jeff Casimir
|
14
9
|
- Steve Klabnik
|
15
10
|
autorequire:
|
16
11
|
bindir: bin
|
17
12
|
cert_chain: []
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
- !ruby/object:Gem::Dependency
|
13
|
+
date: 2012-05-12 00:00:00.000000000 Z
|
14
|
+
dependencies:
|
15
|
+
- !ruby/object:Gem::Dependency
|
22
16
|
name: activesupport
|
23
|
-
|
24
|
-
requirement: &id001 !ruby/object:Gem::Requirement
|
17
|
+
requirement: !ruby/object:Gem::Requirement
|
25
18
|
none: false
|
26
|
-
requirements:
|
27
|
-
- -
|
28
|
-
- !ruby/object:Gem::Version
|
29
|
-
hash: 23
|
30
|
-
segments:
|
31
|
-
- 2
|
32
|
-
- 3
|
33
|
-
- 10
|
19
|
+
requirements:
|
20
|
+
- - ! '>='
|
21
|
+
- !ruby/object:Gem::Version
|
34
22
|
version: 2.3.10
|
35
23
|
type: :runtime
|
36
|
-
version_requirements: *id001
|
37
|
-
- !ruby/object:Gem::Dependency
|
38
|
-
name: rake
|
39
24
|
prerelease: false
|
40
|
-
|
25
|
+
version_requirements: !ruby/object:Gem::Requirement
|
26
|
+
none: false
|
27
|
+
requirements:
|
28
|
+
- - ! '>='
|
29
|
+
- !ruby/object:Gem::Version
|
30
|
+
version: 2.3.10
|
31
|
+
- !ruby/object:Gem::Dependency
|
32
|
+
name: rake
|
33
|
+
requirement: !ruby/object:Gem::Requirement
|
41
34
|
none: false
|
42
|
-
requirements:
|
43
|
-
- -
|
44
|
-
- !ruby/object:Gem::Version
|
45
|
-
|
46
|
-
segments:
|
47
|
-
- 0
|
48
|
-
version: "0"
|
35
|
+
requirements:
|
36
|
+
- - ! '>='
|
37
|
+
- !ruby/object:Gem::Version
|
38
|
+
version: '0'
|
49
39
|
type: :runtime
|
50
|
-
version_requirements: *id002
|
51
|
-
- !ruby/object:Gem::Dependency
|
52
|
-
name: rspec
|
53
40
|
prerelease: false
|
54
|
-
|
41
|
+
version_requirements: !ruby/object:Gem::Requirement
|
42
|
+
none: false
|
43
|
+
requirements:
|
44
|
+
- - ! '>='
|
45
|
+
- !ruby/object:Gem::Version
|
46
|
+
version: '0'
|
47
|
+
- !ruby/object:Gem::Dependency
|
48
|
+
name: rspec
|
49
|
+
requirement: !ruby/object:Gem::Requirement
|
55
50
|
none: false
|
56
|
-
requirements:
|
51
|
+
requirements:
|
57
52
|
- - ~>
|
58
|
-
- !ruby/object:Gem::Version
|
59
|
-
|
60
|
-
segments:
|
61
|
-
- 2
|
62
|
-
- 0
|
63
|
-
version: "2.0"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '2.0'
|
64
55
|
type: :runtime
|
65
|
-
version_requirements: *id003
|
66
|
-
- !ruby/object:Gem::Dependency
|
67
|
-
name: activesupport
|
68
56
|
prerelease: false
|
69
|
-
|
57
|
+
version_requirements: !ruby/object:Gem::Requirement
|
70
58
|
none: false
|
71
|
-
requirements:
|
59
|
+
requirements:
|
72
60
|
- - ~>
|
73
|
-
- !ruby/object:Gem::Version
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
61
|
+
- !ruby/object:Gem::Version
|
62
|
+
version: '2.0'
|
63
|
+
- !ruby/object:Gem::Dependency
|
64
|
+
name: activesupport
|
65
|
+
requirement: !ruby/object:Gem::Requirement
|
66
|
+
none: false
|
67
|
+
requirements:
|
68
|
+
- - ~>
|
69
|
+
- !ruby/object:Gem::Version
|
79
70
|
version: 3.1.3
|
80
71
|
type: :runtime
|
81
|
-
version_requirements: *id004
|
82
|
-
- !ruby/object:Gem::Dependency
|
83
|
-
name: actionpack
|
84
72
|
prerelease: false
|
85
|
-
|
73
|
+
version_requirements: !ruby/object:Gem::Requirement
|
86
74
|
none: false
|
87
|
-
requirements:
|
75
|
+
requirements:
|
88
76
|
- - ~>
|
89
|
-
- !ruby/object:Gem::Version
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
77
|
+
- !ruby/object:Gem::Version
|
78
|
+
version: 3.1.3
|
79
|
+
- !ruby/object:Gem::Dependency
|
80
|
+
name: actionpack
|
81
|
+
requirement: !ruby/object:Gem::Requirement
|
82
|
+
none: false
|
83
|
+
requirements:
|
84
|
+
- - ~>
|
85
|
+
- !ruby/object:Gem::Version
|
95
86
|
version: 3.1.3
|
96
87
|
type: :runtime
|
97
|
-
version_requirements: *id005
|
98
|
-
- !ruby/object:Gem::Dependency
|
99
|
-
name: ammeter
|
100
88
|
prerelease: false
|
101
|
-
|
89
|
+
version_requirements: !ruby/object:Gem::Requirement
|
90
|
+
none: false
|
91
|
+
requirements:
|
92
|
+
- - ~>
|
93
|
+
- !ruby/object:Gem::Version
|
94
|
+
version: 3.1.3
|
95
|
+
- !ruby/object:Gem::Dependency
|
96
|
+
name: ammeter
|
97
|
+
requirement: !ruby/object:Gem::Requirement
|
102
98
|
none: false
|
103
|
-
requirements:
|
99
|
+
requirements:
|
104
100
|
- - ~>
|
105
|
-
- !ruby/object:Gem::Version
|
106
|
-
hash: 19
|
107
|
-
segments:
|
108
|
-
- 0
|
109
|
-
- 2
|
110
|
-
- 2
|
101
|
+
- !ruby/object:Gem::Version
|
111
102
|
version: 0.2.2
|
112
103
|
type: :development
|
113
|
-
version_requirements: *id006
|
114
|
-
- !ruby/object:Gem::Dependency
|
115
|
-
name: guard
|
116
104
|
prerelease: false
|
117
|
-
|
105
|
+
version_requirements: !ruby/object:Gem::Requirement
|
106
|
+
none: false
|
107
|
+
requirements:
|
108
|
+
- - ~>
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: 0.2.2
|
111
|
+
- !ruby/object:Gem::Dependency
|
112
|
+
name: guard
|
113
|
+
requirement: !ruby/object:Gem::Requirement
|
118
114
|
none: false
|
119
|
-
requirements:
|
120
|
-
- -
|
121
|
-
- !ruby/object:Gem::Version
|
122
|
-
|
123
|
-
segments:
|
124
|
-
- 0
|
125
|
-
version: "0"
|
115
|
+
requirements:
|
116
|
+
- - ! '>='
|
117
|
+
- !ruby/object:Gem::Version
|
118
|
+
version: '0'
|
126
119
|
type: :development
|
127
|
-
version_requirements: *id007
|
128
|
-
- !ruby/object:Gem::Dependency
|
129
|
-
name: guard-rspec
|
130
120
|
prerelease: false
|
131
|
-
|
121
|
+
version_requirements: !ruby/object:Gem::Requirement
|
132
122
|
none: false
|
133
|
-
requirements:
|
134
|
-
- -
|
135
|
-
- !ruby/object:Gem::Version
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
123
|
+
requirements:
|
124
|
+
- - ! '>='
|
125
|
+
- !ruby/object:Gem::Version
|
126
|
+
version: '0'
|
127
|
+
- !ruby/object:Gem::Dependency
|
128
|
+
name: guard-rspec
|
129
|
+
requirement: !ruby/object:Gem::Requirement
|
130
|
+
none: false
|
131
|
+
requirements:
|
132
|
+
- - ! '>='
|
133
|
+
- !ruby/object:Gem::Version
|
134
|
+
version: '0'
|
140
135
|
type: :development
|
141
|
-
version_requirements: *id008
|
142
|
-
- !ruby/object:Gem::Dependency
|
143
|
-
name: launchy
|
144
136
|
prerelease: false
|
145
|
-
|
137
|
+
version_requirements: !ruby/object:Gem::Requirement
|
146
138
|
none: false
|
147
|
-
requirements:
|
148
|
-
- -
|
149
|
-
- !ruby/object:Gem::Version
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
139
|
+
requirements:
|
140
|
+
- - ! '>='
|
141
|
+
- !ruby/object:Gem::Version
|
142
|
+
version: '0'
|
143
|
+
- !ruby/object:Gem::Dependency
|
144
|
+
name: launchy
|
145
|
+
requirement: !ruby/object:Gem::Requirement
|
146
|
+
none: false
|
147
|
+
requirements:
|
148
|
+
- - ! '>='
|
149
|
+
- !ruby/object:Gem::Version
|
150
|
+
version: '0'
|
154
151
|
type: :development
|
155
|
-
version_requirements: *id009
|
156
|
-
- !ruby/object:Gem::Dependency
|
157
|
-
name: yard
|
158
152
|
prerelease: false
|
159
|
-
|
153
|
+
version_requirements: !ruby/object:Gem::Requirement
|
160
154
|
none: false
|
161
|
-
requirements:
|
162
|
-
- -
|
163
|
-
- !ruby/object:Gem::Version
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
155
|
+
requirements:
|
156
|
+
- - ! '>='
|
157
|
+
- !ruby/object:Gem::Version
|
158
|
+
version: '0'
|
159
|
+
- !ruby/object:Gem::Dependency
|
160
|
+
name: yard
|
161
|
+
requirement: !ruby/object:Gem::Requirement
|
162
|
+
none: false
|
163
|
+
requirements:
|
164
|
+
- - ! '>='
|
165
|
+
- !ruby/object:Gem::Version
|
166
|
+
version: '0'
|
168
167
|
type: :development
|
169
|
-
|
168
|
+
prerelease: false
|
169
|
+
version_requirements: !ruby/object:Gem::Requirement
|
170
|
+
none: false
|
171
|
+
requirements:
|
172
|
+
- - ! '>='
|
173
|
+
- !ruby/object:Gem::Version
|
174
|
+
version: '0'
|
170
175
|
description: Draper implements a decorator or presenter pattern for Rails applications.
|
171
|
-
email:
|
176
|
+
email:
|
172
177
|
- jeff@casimircreative.com
|
173
178
|
- steve@steveklabnik.com
|
174
179
|
executables: []
|
175
|
-
|
176
180
|
extensions: []
|
177
|
-
|
178
181
|
extra_rdoc_files: []
|
179
|
-
|
180
|
-
files:
|
182
|
+
files:
|
181
183
|
- .gitignore
|
182
184
|
- .rspec
|
183
185
|
- .travis.yml
|
@@ -259,38 +261,29 @@ files:
|
|
259
261
|
- spec/support/samples/widget_decorator.rb
|
260
262
|
homepage: http://github.com/jcasimir/draper
|
261
263
|
licenses: []
|
262
|
-
|
263
264
|
post_install_message:
|
264
265
|
rdoc_options: []
|
265
|
-
|
266
|
-
require_paths:
|
266
|
+
require_paths:
|
267
267
|
- lib
|
268
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
268
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
269
269
|
none: false
|
270
|
-
requirements:
|
271
|
-
- -
|
272
|
-
- !ruby/object:Gem::Version
|
273
|
-
|
274
|
-
|
275
|
-
- 0
|
276
|
-
version: "0"
|
277
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
270
|
+
requirements:
|
271
|
+
- - ! '>='
|
272
|
+
- !ruby/object:Gem::Version
|
273
|
+
version: '0'
|
274
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
278
275
|
none: false
|
279
|
-
requirements:
|
280
|
-
- -
|
281
|
-
- !ruby/object:Gem::Version
|
282
|
-
|
283
|
-
segments:
|
284
|
-
- 0
|
285
|
-
version: "0"
|
276
|
+
requirements:
|
277
|
+
- - ! '>='
|
278
|
+
- !ruby/object:Gem::Version
|
279
|
+
version: '0'
|
286
280
|
requirements: []
|
287
|
-
|
288
281
|
rubyforge_project: draper
|
289
282
|
rubygems_version: 1.8.24
|
290
283
|
signing_key:
|
291
284
|
specification_version: 3
|
292
285
|
summary: Decorator pattern implementation for Rails.
|
293
|
-
test_files:
|
286
|
+
test_files:
|
294
287
|
- spec/draper/base_spec.rb
|
295
288
|
- spec/draper/helper_support_spec.rb
|
296
289
|
- spec/draper/model_support_spec.rb
|