From e0c79b6307c2e7536b5234b269856a0706235212 Mon Sep 17 00:00:00 2001 From: Lars Moelleken Date: Sun, 5 Apr 2020 23:44:45 +0200 Subject: [PATCH] [+]: use a new version of "voku/simple_html_dom" (4.7.16) -> fix issue #49 --- CHANGELOG.md | 4 ++++ composer.json | 2 +- tests/HtmlMinTest.php | 18 ++++++++++++++++++ 3 files changed, 23 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 41d6c0b..22764e0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +# Changelog 4.4.1 (2020-04-05) + +- use a new version of "voku/simple_html_dom" (4.7.16) + # Changelog 4.4.0 (2020-04-05) - add support for removing more default attributes diff --git a/composer.json b/composer.json index 8868c74..9fe3672 100644 --- a/composer.json +++ b/composer.json @@ -19,7 +19,7 @@ ], "require": { "php": ">=7.0.0", - "voku/simple_html_dom": "~4.7.15", + "voku/simple_html_dom": "~4.7.16", "ext-dom": "*" }, "require-dev": { diff --git a/tests/HtmlMinTest.php b/tests/HtmlMinTest.php index ca5f590..8563a64 100644 --- a/tests/HtmlMinTest.php +++ b/tests/HtmlMinTest.php @@ -773,6 +773,24 @@ public function testHtmlInsideJavaScriptTemplates() static::assertSame($expected, $htmlMin->minify($html)); } + public function testHtmlClosingTagInSpecialScript() + { + $htmlMin = new \voku\helper\HtmlMin(); + $htmlMin->doOptimizeViaHtmlDomParser(true); + $html = $htmlMin->minify(' + '); + + $expected = ''; + + static::assertSame($expected, $html); + } + public function testVueJsExample() { // init