Skip to content

Commit 450abc3

Browse files
author
Christoph Singer
committed
Make tests pass in PHP8
libxml as of PHP8 seems to remove equal sign and quotes from empty attributes
1 parent 5803f0f commit 450abc3

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Tests/PrettyMinTest.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ public function testMinify()
5757

5858
$expected = <<<HTML
5959
<!DOCTYPE html>
60-
<html><head><title>Test</title><script>$(document).ready(function(){if(this&&that&&a>b){doSomething();}});</script><style>body>div{border-top:1px solid green}</style></head><body><h1>Test</h1><div class="keep"><div><p>This is <b>bold</b> Text. And some more text, still in the same paragraph. <strong>Inline tag </strong>whith whitespace at the end but not after.</p><p>This is another paragraph with a <a href="">link</a>.</p></div></div><form><input type="text" name="a"><input type="text" name="b"></form></body></html>
60+
<html><head><title>Test</title><script>$(document).ready(function(){if(this&&that&&a>b){doSomething();}});</script><style>body>div{border-top:1px solid green}</style></head><body><h1>Test</h1><div class="keep"><div><p>This is <b>bold</b> Text. And some more text, still in the same paragraph. <strong>Inline tag </strong>whith whitespace at the end but not after.</p><p>This is another paragraph with a <a href>link</a>.</p></div></div><form><input type="text" name="a"><input type="text" name="b"></form></body></html>
6161
6262
HTML;
6363

@@ -123,9 +123,9 @@ function () {
123123
<body>
124124
<h1>Test</h1>
125125
<div class="keep">
126-
<div class="" style="">
126+
<div class style>
127127
<p>This is <b>bold</b> Text. And some more text, still in the same paragraph. <strong>Inline tag </strong>whith whitespace at the end but not after.</p>
128-
<p>This is another paragraph with a <a href="">link</a>.</p>
128+
<p>This is another paragraph with a <a href>link</a>.</p>
129129
</div>
130130
</div>
131131
<form><input type="text" name="a"><input type="text" name="b"></form>

0 commit comments

Comments
 (0)