Use assert_predicate instead

Co-authored-by: no-itsbackpack <no-itsbackpack@github.com>
This commit is contained in:
Yumin Wong 2018-09-06 12:48:50 -05:00
parent 3f5bd11ed6
commit 0a1567793b

@ -153,13 +153,13 @@ def test_titleize
test "Should continue safe on slice" do
x = "<div>foo</div>".html_safe
assert x.html_safe?, "should be safe"
assert_predicate x, :html_safe?
# getting a slice of it
y = x[0..-1]
# should still be safe
assert y.html_safe?, "should be safe"
assert_predicate y, :html_safe?
end
test "Should work with interpolation (array argument)" do