padrino-helpers 0.14.0 → 0.14.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/padrino-helpers/render_helpers.rb +1 -1
- data/test/fixtures/render_app/app.rb +4 -0
- data/test/fixtures/render_app/views/_foo.haml +1 -0
- data/test/fixtures/render_app/views/index.haml +1 -0
- data/test/fixtures/render_app/views/layouts/application.haml +5 -0
- data/test/test_render_helpers.rb +7 -0
- metadata +7 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b7a9ae7a5e9911a727eabc62e66ef72b8968cffa
|
4
|
+
data.tar.gz: 75398beb2307394c8fdfd6835e79aacd001b635c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2ba1b632a16819380b4aed481b1aa81531795ccb27e15074fb0a793a5fdd561bbdbd383324be79a573ad40006a805acadbc4ad9272c8d50693f210db865eed3f
|
7
|
+
data.tar.gz: 7027a278b5ec597a20547466b9e785c58faabe73c65bf5fd463e8d3682b48a76b842f97de8924d4b511f79e4bf1a8d434163835529117012436e2e43032ea41a
|
@@ -31,7 +31,7 @@ module Padrino
|
|
31
31
|
# @note If using this from Sinatra, pass explicit +:engine+ option
|
32
32
|
#
|
33
33
|
def partial(template, options={}, &block)
|
34
|
-
options = options
|
34
|
+
options = { :layout => false }.update(options)
|
35
35
|
explicit_engine = options.delete(:engine)
|
36
36
|
|
37
37
|
path, _, name = template.to_s.rpartition(File::SEPARATOR)
|
@@ -0,0 +1 @@
|
|
1
|
+
foo
|
@@ -0,0 +1 @@
|
|
1
|
+
= partial 'foo'
|
data/test/test_render_helpers.rb
CHANGED
@@ -264,4 +264,11 @@ describe "RenderHelpers" do
|
|
264
264
|
assert_equal '_none', Standalone4.new.partial('none')
|
265
265
|
end
|
266
266
|
end
|
267
|
+
|
268
|
+
describe 'partial in an application with layout' do
|
269
|
+
it 'should not render with default layout' do
|
270
|
+
get '/'
|
271
|
+
assert_response_has_tag 'body', :count => 1
|
272
|
+
end
|
273
|
+
end
|
267
274
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: padrino-helpers
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.14.0
|
4
|
+
version: 0.14.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Padrino Team
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: bin
|
13
13
|
cert_chain: []
|
14
|
-
date: 2017-03-
|
14
|
+
date: 2017-03-23 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: padrino-support
|
@@ -19,14 +19,14 @@ dependencies:
|
|
19
19
|
requirements:
|
20
20
|
- - '='
|
21
21
|
- !ruby/object:Gem::Version
|
22
|
-
version: 0.14.0
|
22
|
+
version: 0.14.0.1
|
23
23
|
type: :runtime
|
24
24
|
prerelease: false
|
25
25
|
version_requirements: !ruby/object:Gem::Requirement
|
26
26
|
requirements:
|
27
27
|
- - '='
|
28
28
|
- !ruby/object:Gem::Version
|
29
|
-
version: 0.14.0
|
29
|
+
version: 0.14.0.1
|
30
30
|
- !ruby/object:Gem::Dependency
|
31
31
|
name: tilt
|
32
32
|
requirement: !ruby/object:Gem::Requirement
|
@@ -181,6 +181,7 @@ files:
|
|
181
181
|
- test/fixtures/render_app/views/_deep.erb
|
182
182
|
- test/fixtures/render_app/views/_deep.haml
|
183
183
|
- test/fixtures/render_app/views/_deep.slim
|
184
|
+
- test/fixtures/render_app/views/_foo.haml
|
184
185
|
- test/fixtures/render_app/views/_partial_block_erb.erb
|
185
186
|
- test/fixtures/render_app/views/_partial_block_haml.haml
|
186
187
|
- test/fixtures/render_app/views/_partial_block_slim.slim
|
@@ -202,6 +203,8 @@ files:
|
|
202
203
|
- test/fixtures/render_app/views/erb/test.erb
|
203
204
|
- test/fixtures/render_app/views/explicit_engine.haml
|
204
205
|
- test/fixtures/render_app/views/haml/test.haml
|
206
|
+
- test/fixtures/render_app/views/index.haml
|
207
|
+
- test/fixtures/render_app/views/layouts/application.haml
|
205
208
|
- test/fixtures/render_app/views/render_block_erb.erb
|
206
209
|
- test/fixtures/render_app/views/render_block_haml.haml
|
207
210
|
- test/fixtures/render_app/views/render_block_slim.slim
|