Fix random test failures in TestExcerpt #to_liquid. (#8884)

Merge pull request 8884
This commit is contained in:
Phil Ross 2021-11-17 09:48:03 +00:00 committed by GitHub
parent d81cc40c9f
commit 3a688fe55a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 0 deletions

View File

@ -37,6 +37,7 @@ class TestFilters < JekyllUnitTest
context "filters" do context "filters" do
setup do setup do
@sample_time = Time.utc(2013, 3, 27, 11, 22, 33) @sample_time = Time.utc(2013, 3, 27, 11, 22, 33)
@timezone_before_test = ENV["TZ"]
@filter = make_filter_mock( @filter = make_filter_mock(
"timezone" => "UTC", "timezone" => "UTC",
"url" => "http://example.com", "url" => "http://example.com",
@ -55,6 +56,10 @@ class TestFilters < JekyllUnitTest
] ]
end end
teardown do
ENV["TZ"] = @timezone_before_test
end
should "markdownify with simple string" do should "markdownify with simple string" do
assert_equal( assert_equal(
"<p>something <strong>really</strong> simple</p>\n", "<p>something <strong>really</strong> simple</p>\n",