mirror of
https://github.com/sinatra/sinatra
synced 2023-03-27 23:18:01 -04:00
`attr_wrapper` has been renamed to `attr_quote` Fix slim tests to handle this change
This commit is contained in:
parent
e8899802e2
commit
c0eb49ea4e
1 changed files with 4 additions and 4 deletions
|
@ -48,7 +48,7 @@ class SlimTest < Test::Unit::TestCase
|
||||||
HTML4_DOCTYPE = "<!DOCTYPE html PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">"
|
HTML4_DOCTYPE = "<!DOCTYPE html PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">"
|
||||||
|
|
||||||
it "passes slim options to the slim engine" do
|
it "passes slim options to the slim engine" do
|
||||||
mock_app { get('/') { slim("x foo='bar'", :attr_wrapper => "'") }}
|
mock_app { get('/') { slim("x foo='bar'", :attr_quote => "'") }}
|
||||||
get '/'
|
get '/'
|
||||||
assert ok?
|
assert ok?
|
||||||
assert_body "<x foo='bar'></x>"
|
assert_body "<x foo='bar'></x>"
|
||||||
|
@ -56,7 +56,7 @@ class SlimTest < Test::Unit::TestCase
|
||||||
|
|
||||||
it "passes default slim options to the slim engine" do
|
it "passes default slim options to the slim engine" do
|
||||||
mock_app do
|
mock_app do
|
||||||
set :slim, :attr_wrapper => "'"
|
set :slim, :attr_quote => "'"
|
||||||
get('/') { slim("x foo='bar'") }
|
get('/') { slim("x foo='bar'") }
|
||||||
end
|
end
|
||||||
get '/'
|
get '/'
|
||||||
|
@ -66,9 +66,9 @@ class SlimTest < Test::Unit::TestCase
|
||||||
|
|
||||||
it "merges the default slim options with the overrides and passes them to the slim engine" do
|
it "merges the default slim options with the overrides and passes them to the slim engine" do
|
||||||
mock_app do
|
mock_app do
|
||||||
set :slim, :attr_wrapper => "'"
|
set :slim, :attr_quote => "'"
|
||||||
get('/') { slim("x foo='bar'") }
|
get('/') { slim("x foo='bar'") }
|
||||||
get('/other') { slim("x foo='bar'", :attr_wrapper => '"') }
|
get('/other') { slim("x foo='bar'", :attr_quote => '"') }
|
||||||
end
|
end
|
||||||
get '/'
|
get '/'
|
||||||
assert ok?
|
assert ok?
|
||||||
|
|
Loading…
Reference in a new issue