test/slim/test_embedded_engines.rb in slim-1.1.1 vs test/slim/test_embedded_engines.rb in slim-1.2.0
- old
+ new
@@ -13,18 +13,17 @@
assert_html "<p><b>Hello from BEFORE ERB BLOCK!</b>\nSecond Line!\ntrue</p>", source
end
def test_render_with_markdown
- # Keep the trailing spaces.
source = %q{
markdown:
#Header
Hello from #{"Markdown!"}
-
+
#{1+2}
-
+
* one
* two
}
assert_html "<h1 id=\"header\">Header</h1>\n<p>Hello from Markdown!</p>\n\n<p>3</p>\n\n<ul>\n <li>one</li>\n <li>two</li>\n</ul>\n", source
@@ -75,10 +74,9 @@
}
assert_html %{<script type="text/javascript">$(function() {});\n\n\nalert('hello')</script><p>Hi</p>}, source
end
def test_render_with_javascript_with_tabs
- # Keep the trailing space behind "javascript: "!
source = "javascript:\n\t$(function() {});\n\talert('hello')\np Hi"
assert_html "<script type=\"text/javascript\">$(function() {});\nalert('hello')</script><p>Hi</p>", source
end
def test_render_with_javascript_including_variable