Prefer using assert_instance_of

To appease RuboCop `Minitest/AssertInstanceOf`
This commit is contained in:
Ashwin Maroli
2023-04-09 19:48:28 +05:30
committed by GitHub
parent 7785ef670f
commit bb954ff16e

View File

@@ -384,8 +384,8 @@ class TestPage < JekyllUnitTest
should "initialize excerpt eagerly but render only when needed" do
test_page = Jekyll::Page.new(@configured_site, source_dir, "contacts", "foo.md")
assert_equal Jekyll::PageExcerpt, test_page.data["excerpt"].class
assert_equal String, test_page.excerpt.class
assert_instance_of Jekyll::PageExcerpt, test_page.data["excerpt"]
assert_instance_of String, test_page.excerpt
assert_equal(
"<h2 id=\"contact-information\">Contact Information</h2>\n",
test_page.excerpt