]> source.dussan.org Git - rspamd.git/commitdiff
[Test] Fix broken tests as it is confirmed by browser \m/
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Fri, 2 Jul 2021 10:35:15 +0000 (11:35 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Fri, 2 Jul 2021 10:35:15 +0000 (11:35 +0100)
src/libserver/html/html.cxx
test/lua/unit/html.lua

index 967411b2ae2985004d8b507b2de96497909d3675..68751834366c1cb5d02881e00197bd78043646f1 100644 (file)
@@ -1930,13 +1930,6 @@ TEST_CASE("html text extraction")
 {
 
        const std::vector<std::pair<std::string, std::string>> cases{
-                       {"  <body>\n"
-                        "    <!-- page content -->\n"
-                        "    Hello, world!<br>test</br><br>content</hr>more content<br>\n"
-                        "    <div>\n"
-                        "      content inside div\n"
-                        "    </div>\n"
-                        "  </body>", "Hello, world!\ntest\ncontent\nmore content\ncontent inside div\n"},
                        {"  <body>\n"
                         "    <!-- escape content -->\n"
                         "    a&nbsp;b a &gt; b a &lt; b a &amp; b &apos;a &quot;a&quot;\n"
@@ -2000,7 +1993,13 @@ TEST_CASE("html text extraction")
                         "        <td>data2</td>\n"
                         "      </tr>\n"
                         "    </table>", "heada headb\ndata1 data2\n"},
-
+                       {"  <body>\n"
+                        "    <!-- page content -->\n"
+                        "    Hello, world!<br>test</br><br>content</hr>more content<br>\n"
+                        "    <div>\n"
+                        "      content inside div\n"
+                        "    </div>\n"
+                        "  </body>", "Hello, world!\ntest\ncontentmore content\ncontent inside div\n"},
        };
 
        rspamd_url_init(NULL);
index 8582c4edc8fde5de72ccf65f024657468db798fe..81c52ec1bb65a9a4bdf4d3ebff482a98290f6545 100644 (file)
@@ -56,7 +56,7 @@ context("HTML processing", function()
     </div>
   </body>
 </html>
-      ]], 'Hello, world!\ntest\ncontent\nmore content\ncontent inside div\n'},
+      ]], 'Hello, world!\ntest\ncontentmore content\ncontent inside div\n'},
       {[[
 <html lang="en">
   <head>