<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">https://github.com/shlomif/perl-XML-LibXML/pull/87

From c9f9c2fe51173b0a00969f01b577399f1098aa47 Mon Sep 17 00:00:00 2001
From: Nick Wellnhofer &lt;wellnhofer@aevum.de&gt;
Date: Thu, 13 Feb 2025 19:50:35 +0100
Subject: [PATCH] Fix test suite with libxml2 2.14.0

--- a/t/16docnodes.t
+++ b/t/16docnodes.t
@@ -60,7 +60,12 @@ for my $time (0 .. 2) {
     $doc-&gt;setDocumentElement($node);
 
     # TEST
-    is( $node-&gt;serialize(), '&lt;test contents="&amp;#xE4;"/&gt;', 'Node serialise works.' );
+    # libxml2 2.14 avoids unnecessary escaping of attribute values.
+    if (XML::LibXML::LIBXML_VERSION() &gt;= 21400) {
+        is( $node-&gt;serialize(), "&lt;test contents=\"\xE4\"/&gt;", 'Node serialise works.' );
+    } else {
+        is( $node-&gt;serialize(), '&lt;test contents="&amp;#xE4;"/&gt;', 'Node serialise works.' );
+    }
 
     $doc-&gt;setEncoding('utf-8');
     # Second output
--- a/t/49_load_html.t
+++ b/t/49_load_html.t
@@ -52,7 +52,13 @@ use XML::LibXML;
 &lt;/div&gt;
 EOS
 
-    {
+    SKIP: {
+        # libxml2 2.14 tokenizes HTML according to HTML5 where
+        # this isn't an error, see "13.2.5.73 Named character
+        # reference state".
+        skip("libxml2 version &gt;= 21400", 1)
+            if XML::LibXML::LIBXML_VERSION &gt;= 21400;
+
         my $buf = '';
         open my $fh, '&gt;', \$buf;
         # redirect STDERR there
</pre></body></html>