summaryrefslogtreecommitdiffstats
path: root/layout/tables/reftests
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 19:33:14 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 19:33:14 +0000
commit36d22d82aa202bb199967e9512281e9a53db42c9 (patch)
tree105e8c98ddea1c1e4784a60a5a6410fa416be2de /layout/tables/reftests
parentInitial commit. (diff)
downloadfirefox-esr-upstream.tar.xz
firefox-esr-upstream.zip
Adding upstream version 115.7.0esr.upstream/115.7.0esrupstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'layout/tables/reftests')
-rw-r--r--layout/tables/reftests/1017137-ref.html27
-rw-r--r--layout/tables/reftests/1017137.html27
-rw-r--r--layout/tables/reftests/1031934-ref.html27
-rw-r--r--layout/tables/reftests/1031934.html54
-rw-r--r--layout/tables/reftests/1220621-1-ref.html17
-rw-r--r--layout/tables/reftests/1220621-1a.html32
-rw-r--r--layout/tables/reftests/1220621-1b.html31
-rw-r--r--layout/tables/reftests/1220621-1c.html30
-rw-r--r--layout/tables/reftests/1220621-1d.html34
-rw-r--r--layout/tables/reftests/1220621-1e.html34
-rw-r--r--layout/tables/reftests/1220621-1f.html32
-rw-r--r--layout/tables/reftests/1220621-2-ref.html21
-rw-r--r--layout/tables/reftests/1220621-2a.html29
-rw-r--r--layout/tables/reftests/1220621-2b.html32
-rw-r--r--layout/tables/reftests/1564308-ref.html22
-rw-r--r--layout/tables/reftests/1564308.html40
-rw-r--r--layout/tables/reftests/dynamic-text-indent-table-cell-ref.html10
-rw-r--r--layout/tables/reftests/dynamic-text-indent-table-cell.html19
-rw-r--r--layout/tables/reftests/dynamic-text-overflow-table-cell-notref.html8
-rw-r--r--layout/tables/reftests/dynamic-text-overflow-table-cell-ref.html8
-rw-r--r--layout/tables/reftests/dynamic-text-overflow-table-cell.html19
-rw-r--r--layout/tables/reftests/reftest.list14
22 files changed, 567 insertions, 0 deletions
diff --git a/layout/tables/reftests/1017137-ref.html b/layout/tables/reftests/1017137-ref.html
new file mode 100644
index 0000000000..ae9f89a849
--- /dev/null
+++ b/layout/tables/reftests/1017137-ref.html
@@ -0,0 +1,27 @@
+<!DOCTYPE html>
+<html class="reftest-paged">
+<head>
+ <title>Reference: Table fragmentation test</title>
+ <link rel="author" title="Mats Palmgren" href="https://bugzilla.mozilla.org/show_bug.cgi?id=1017137">
+ <meta charset="utf-8">
+ <meta name="flags" content="paged">
+ <style>
+@page { size:5in 3in; margin:0.5in; }
+html,body {
+ color:black; background-color:white; font:16px/1 monospace; padding:0; margin:0;
+}
+table,tr,td { border:0; padding:0; margin:0; }
+</style>
+</head>
+
+<body>
+ <table cellspacing=0 cellpadding=0>
+ <tr id="_TR_1"><td>
+ <div style="height:0.2in"></div>
+ </td></tr>
+
+ <tr id="_TR_2"><td>
+ <table cellspacing=0 cellpadding=0><tr><td><div style="height:0.5in; margin-top:64px"></div></td></tr></table>
+ </td></tr>
+
+ <tr id="_TR_3" style="page-break-before:always"><td>HELLO KITTY
diff --git a/layout/tables/reftests/1017137.html b/layout/tables/reftests/1017137.html
new file mode 100644
index 0000000000..1778d3b566
--- /dev/null
+++ b/layout/tables/reftests/1017137.html
@@ -0,0 +1,27 @@
+<!DOCTYPE html>
+<html class="reftest-paged">
+<head>
+ <title>Table fragmentation test</title>
+ <link rel="author" title="Mats Palmgren" href="https://bugzilla.mozilla.org/show_bug.cgi?id=1017137">
+ <meta charset="utf-8">
+ <meta name="flags" content="paged">
+ <style>
+@page { size:5in 3in; margin:0.5in; }
+html,body {
+ color:black; background-color:white; font:16px/1 monospace; padding:0; margin:0;
+}
+table,tr,td { border:0; padding:0; margin:0; }
+</style>
+</head>
+
+<body>
+ <table cellspacing=0 cellpadding=0>
+ <tr id="_TR_1"><td>
+ <div style="height:0.2in"></div>
+ </td></tr>
+
+ <tr id="_TR_2"><td>
+ <table cellspacing=0 cellpadding=0><tr><td><div style="height:0.5in; margin:64px 0"></div></td></tr></table>
+ </td></tr>
+
+ <tr id="_TR_3"><td>HELLO KITTY
diff --git a/layout/tables/reftests/1031934-ref.html b/layout/tables/reftests/1031934-ref.html
new file mode 100644
index 0000000000..660e00a750
--- /dev/null
+++ b/layout/tables/reftests/1031934-ref.html
@@ -0,0 +1,27 @@
+<!DOCTYPE HTML>
+<html><head>
+ <meta charset="utf-8">
+ <title>Testcase for bug 1031934</title>
+</head>
+<body>
+
+<table border="1">
+<tbody style="visibility: collapse;">
+</tbody>
+<tbody>
+<tr><td>Hello</td></tr>
+</tbody>
+<tbody style="visibility: collapse;">
+</tbody>
+</table>
+
+<table border="1">
+<tbody></tbody>
+<tbody>
+<tr><td>Hello</td></tr>
+</tbody>
+<tbody></tbody>
+</table>
+
+</body>
+</html>
diff --git a/layout/tables/reftests/1031934.html b/layout/tables/reftests/1031934.html
new file mode 100644
index 0000000000..9477e0e790
--- /dev/null
+++ b/layout/tables/reftests/1031934.html
@@ -0,0 +1,54 @@
+<!DOCTYPE HTML>
+<html><head>
+ <meta charset="utf-8">
+ <title>Testcase for bug 1031934</title>
+ <style type="text/css">
+
+td { display:none; }
+
+ </style>
+</head>
+<body>
+
+<table border="1">
+<tbody style="visibility: collapse;">
+<tr><td></td></tr>
+<tr><td></td></tr>
+<tr><td></td></tr>
+<tr><td></td></tr>
+<tr><td></td></tr>
+</tbody>
+<tbody>
+<tr><td></td></tr>
+<tr><td style="display:table-cell">Hello</td></tr>
+<tr><td></td></tr>
+</tbody>
+<tbody style="visibility: collapse;">
+<tr><td></td></tr>
+<tr><td></td></tr>
+<tr><td></td></tr>
+<tr><td></td></tr>
+<tr><td></td></tr>
+</tbody>
+</table>
+
+<table border="1">
+<tbody>
+<tr style="visibility: collapse;"><td></td></tr>
+<tr style="visibility: collapse;"><td></td></tr>
+<tr style="visibility: collapse;"><td></td></tr>
+</tbody>
+<tbody>
+<tr><td></td></tr>
+<tr><td style="display:table-cell">Hello</td></tr>
+<tr><td></td></tr>
+</tbody>
+<tbody style="visibility: collapse;">
+<tr style="visibility: collapse;"><td></td></tr>
+<tr style="visibility: collapse;"><td></td></tr>
+<tr style="visibility: collapse;"><td></td></tr>
+</tbody>
+</table>
+
+</body>
+</html>
diff --git a/layout/tables/reftests/1220621-1-ref.html b/layout/tables/reftests/1220621-1-ref.html
new file mode 100644
index 0000000000..bc9e9006cb
--- /dev/null
+++ b/layout/tables/reftests/1220621-1-ref.html
@@ -0,0 +1,17 @@
+<!DOCTYPE html>
+<style>
+ table {
+ table-layout: fixed;
+ border: 1px solid black;
+ width: 300px;
+ }
+ td {
+ background: yellow;
+ border: 1px solid purple;
+ }
+</style>
+<table>
+ <td>One</td>
+ <td>Two</td>
+ <td>Three</td>
+</table>
diff --git a/layout/tables/reftests/1220621-1a.html b/layout/tables/reftests/1220621-1a.html
new file mode 100644
index 0000000000..70026618a1
--- /dev/null
+++ b/layout/tables/reftests/1220621-1a.html
@@ -0,0 +1,32 @@
+<!DOCTYPE html>
+<style>
+ table {
+ table-layout: fixed;
+ border: 1px solid black;
+ width: 300px;
+ }
+ td {
+ background: yellow;
+ border: 1px solid purple;
+ }
+</style>
+<table>
+ <colgroup>
+ <col>
+ <col>
+ <col>
+ <col>
+ </colgroup>
+ <tbody>
+ <td>One</td>
+ <td>Two</td>
+ <td>Three</td>
+ </tbody>
+</table>
+<script>
+ var t = document.querySelector("table");
+ // Flush layout
+ var width = t.offsetWidth;
+ // Remove the first col
+ document.querySelector("col").remove();
+</script>
diff --git a/layout/tables/reftests/1220621-1b.html b/layout/tables/reftests/1220621-1b.html
new file mode 100644
index 0000000000..82ab75544f
--- /dev/null
+++ b/layout/tables/reftests/1220621-1b.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html>
+<style>
+ table {
+ table-layout: fixed;
+ border: 1px solid black;
+ width: 300px;
+ }
+ td {
+ background: yellow;
+ border: 1px solid purple;
+ }
+</style>
+<table>
+ <colgroup>
+ <col>
+ <col>
+ <col>
+ </colgroup>
+ <tbody>
+ <td>One</td>
+ <td>Two</td>
+ <td>Three</td>
+ </tbody>
+</table>
+<script>
+ var t = document.querySelector("table");
+ // Flush layout
+ var width = t.offsetWidth;
+ // Remove the first col
+ document.querySelector("col").remove();
+</script>
diff --git a/layout/tables/reftests/1220621-1c.html b/layout/tables/reftests/1220621-1c.html
new file mode 100644
index 0000000000..3d0949abc9
--- /dev/null
+++ b/layout/tables/reftests/1220621-1c.html
@@ -0,0 +1,30 @@
+<!DOCTYPE html>
+<style>
+ table {
+ table-layout: fixed;
+ border: 1px solid black;
+ width: 300px;
+ }
+ td {
+ background: yellow;
+ border: 1px solid purple;
+ }
+</style>
+<table>
+ <colgroup>
+ <col>
+ <col>
+ </colgroup>
+ <tbody>
+ <td>One</td>
+ <td>Two</td>
+ <td>Three</td>
+ </tbody>
+</table>
+<script>
+ var t = document.querySelector("table");
+ // Flush layout
+ var width = t.offsetWidth;
+ // Remove the first col
+ document.querySelector("col").remove();
+</script>
diff --git a/layout/tables/reftests/1220621-1d.html b/layout/tables/reftests/1220621-1d.html
new file mode 100644
index 0000000000..cf6291d87b
--- /dev/null
+++ b/layout/tables/reftests/1220621-1d.html
@@ -0,0 +1,34 @@
+<!DOCTYPE html>
+<style>
+ table {
+ table-layout: fixed;
+ border: 1px solid black;
+ width: 300px;
+ }
+ td {
+ background: yellow;
+ border: 1px solid purple;
+ }
+</style>
+<table>
+ <colgroup>
+ <col>
+ </colgroup>
+ <colgroup>
+ <col>
+ <col>
+ <col>
+ </colgroup>
+ <tbody>
+ <td>One</td>
+ <td>Two</td>
+ <td>Three</td>
+ </tbody>
+</table>
+<script>
+ var t = document.querySelector("table");
+ // Flush layout
+ var width = t.offsetWidth;
+ // Remove the first colgroup
+ document.querySelector("colgroup").remove();
+</script>
diff --git a/layout/tables/reftests/1220621-1e.html b/layout/tables/reftests/1220621-1e.html
new file mode 100644
index 0000000000..44e8b94e28
--- /dev/null
+++ b/layout/tables/reftests/1220621-1e.html
@@ -0,0 +1,34 @@
+<!DOCTYPE html>
+<style>
+ table {
+ table-layout: fixed;
+ border: 1px solid black;
+ width: 300px;
+ }
+ td {
+ background: yellow;
+ border: 1px solid purple;
+ }
+</style>
+<table>
+ <colgroup>
+ <col>
+ <col>
+ </colgroup>
+ <colgroup>
+ <col>
+ <col>
+ </colgroup>
+ <tbody>
+ <td>One</td>
+ <td>Two</td>
+ <td>Three</td>
+ </tbody>
+</table>
+<script>
+ var t = document.querySelector("table");
+ // Flush layout
+ var width = t.offsetWidth;
+ // Remove the one colgroup
+ document.querySelector("colgroup").remove();
+</script>
diff --git a/layout/tables/reftests/1220621-1f.html b/layout/tables/reftests/1220621-1f.html
new file mode 100644
index 0000000000..0b5f9a84e2
--- /dev/null
+++ b/layout/tables/reftests/1220621-1f.html
@@ -0,0 +1,32 @@
+<!DOCTYPE html>
+<style>
+ table {
+ table-layout: fixed;
+ border: 1px solid black;
+ width: 300px;
+ }
+ td {
+ background: yellow;
+ border: 1px solid purple;
+ }
+</style>
+<table>
+ <colgroup>
+ <col>
+ <col>
+ <col>
+ <col>
+ </colgroup>
+ <tbody>
+ <td>One</td>
+ <td>Two</td>
+ <td>Three</td>
+ </tbody>
+</table>
+<script>
+ var t = document.querySelector("table");
+ // Flush layout
+ var width = t.offsetWidth;
+ // Remove the one colgroup
+ document.querySelector("colgroup").remove();
+</script>
diff --git a/layout/tables/reftests/1220621-2-ref.html b/layout/tables/reftests/1220621-2-ref.html
new file mode 100644
index 0000000000..b6a02820b2
--- /dev/null
+++ b/layout/tables/reftests/1220621-2-ref.html
@@ -0,0 +1,21 @@
+<!DOCTYPE html>
+<style>
+ table {
+ table-layout: fixed;
+ border: 1px solid black;
+ width: 300px;
+ }
+ td {
+ background: yellow;
+ border: 1px solid purple;
+ }
+</style>
+<table>
+ <colgroup>
+ <col>
+ <col>
+ </colgroup>
+ <tbody>
+ <td>One</td>
+ </tbody>
+</table>
diff --git a/layout/tables/reftests/1220621-2a.html b/layout/tables/reftests/1220621-2a.html
new file mode 100644
index 0000000000..a66768e0fc
--- /dev/null
+++ b/layout/tables/reftests/1220621-2a.html
@@ -0,0 +1,29 @@
+<!DOCTYPE html>
+<style>
+ table {
+ table-layout: fixed;
+ border: 1px solid black;
+ width: 300px;
+ }
+ td {
+ background: yellow;
+ border: 1px solid purple;
+ }
+</style>
+<table>
+ <colgroup>
+ <col>
+ <col>
+ <col>
+ </colgroup>
+ <tbody>
+ <td>One</td>
+ </tbody>
+</table>
+<script>
+ var t = document.querySelector("table");
+ // Flush layout
+ var width = t.offsetWidth;
+ // Remove the first col
+ document.querySelector("col").remove();
+</script>
diff --git a/layout/tables/reftests/1220621-2b.html b/layout/tables/reftests/1220621-2b.html
new file mode 100644
index 0000000000..379857235b
--- /dev/null
+++ b/layout/tables/reftests/1220621-2b.html
@@ -0,0 +1,32 @@
+<!DOCTYPE html>
+<style>
+ table {
+ table-layout: fixed;
+ border: 1px solid black;
+ width: 300px;
+ }
+ td {
+ background: yellow;
+ border: 1px solid purple;
+ }
+</style>
+<table>
+ <colgroup>
+ <col>
+ <col>
+ </colgroup>
+ <colgroup>
+ <col>
+ <col>
+ </colgroup>
+ <tbody>
+ <td>One</td>
+ </tbody>
+</table>
+<script>
+ var t = document.querySelector("table");
+ // Flush layout
+ var width = t.offsetWidth;
+ // Remove the first col
+ document.querySelector("colgroup").remove();
+</script>
diff --git a/layout/tables/reftests/1564308-ref.html b/layout/tables/reftests/1564308-ref.html
new file mode 100644
index 0000000000..5dcd33a628
--- /dev/null
+++ b/layout/tables/reftests/1564308-ref.html
@@ -0,0 +1,22 @@
+<!DOCTYPE HTML>
+<html><head>
+ <meta charset="utf-8">
+ <title>Testcase for bug 1564308</title>
+ <style type="text/css">
+
+html { overflow: scroll } /* suppress resizes for scrollbars */
+
+ </style>
+</head>
+<body style="height: 300px; width: 20em;">
+
+<div style="display:inline">
+<table border="1" style="display:inline-table; vertical-align: top;">
+<tbody>
+<tr><td>Hello</td></tr>
+</tbody>
+</table>
+</div>
+
+</body>
+</html>
diff --git a/layout/tables/reftests/1564308.html b/layout/tables/reftests/1564308.html
new file mode 100644
index 0000000000..1172c33fe9
--- /dev/null
+++ b/layout/tables/reftests/1564308.html
@@ -0,0 +1,40 @@
+<!DOCTYPE HTML>
+<html><head>
+ <meta charset="utf-8">
+ <title>Testcase for bug 1564308</title>
+ <style type="text/css">
+
+html { overflow: scroll } /* suppress resizes for scrollbars */
+
+ </style>
+</head>
+<body style="height: 300px">
+
+<div style="display:inline">
+<table border="1" style="display:inline-table; vertical-align: top;">
+<tbody style="visibility: collapse;">
+<tr><td></td></tr>
+<tr><td></td></tr>
+<tr><td></td></tr>
+<tr><td></td></tr>
+<tr><td></td></tr>
+</tbody>
+<tbody>
+<tr><td>Hello</td></tr>
+</tbody>
+</table>
+</div>
+
+<script>
+
+// This, plus the use of an inline-table wrapped by an inline, is a relatively
+// complicated setup to cause the table to be reflowed while it is not dirty,
+// has no dirty descendants, and is not vertically or horizontally resizing, so
+// that nsTableFrame::Reflow will skip the main part of the function.
+document.body.offsetWidth;
+document.body.style.width = "20em";
+
+</script>
+
+</body>
+</html>
diff --git a/layout/tables/reftests/dynamic-text-indent-table-cell-ref.html b/layout/tables/reftests/dynamic-text-indent-table-cell-ref.html
new file mode 100644
index 0000000000..de749b910a
--- /dev/null
+++ b/layout/tables/reftests/dynamic-text-indent-table-cell-ref.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<html>
+ <table>
+ <tr>
+ <td style="text-indent: 50px">
+ Some text
+ </td>
+ </tr>
+ </table>
+</html>
diff --git a/layout/tables/reftests/dynamic-text-indent-table-cell.html b/layout/tables/reftests/dynamic-text-indent-table-cell.html
new file mode 100644
index 0000000000..c49271a61f
--- /dev/null
+++ b/layout/tables/reftests/dynamic-text-indent-table-cell.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <table>
+ <tr>
+ <td>
+ Some text
+ </td>
+ </tr>
+ </table>
+ <script>
+ onload = function() {
+ var td = document.querySelector("td");
+ // Make sure layout has happened.
+ var width = td.offsetWidth;
+ td.style.textIndent = "50px";
+ document.documentElement.className = "";
+ }
+ </script>
+</html>
diff --git a/layout/tables/reftests/dynamic-text-overflow-table-cell-notref.html b/layout/tables/reftests/dynamic-text-overflow-table-cell-notref.html
new file mode 100644
index 0000000000..4cbdc4f813
--- /dev/null
+++ b/layout/tables/reftests/dynamic-text-overflow-table-cell-notref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<table style="table-layout: fixed; width: 130px">
+ <tr>
+ <td style="overflow: hidden; white-space: nowrap;">
+ Some long text that cannot possibly fit in 130 px, because it just can't.
+ </td>
+ </tr>
+</table>
diff --git a/layout/tables/reftests/dynamic-text-overflow-table-cell-ref.html b/layout/tables/reftests/dynamic-text-overflow-table-cell-ref.html
new file mode 100644
index 0000000000..c19925ba60
--- /dev/null
+++ b/layout/tables/reftests/dynamic-text-overflow-table-cell-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<table style="table-layout: fixed; width: 130px">
+ <tr>
+ <td style="overflow: hidden; white-space: nowrap; text-overflow: ellipsis">
+ Some long text that cannot possibly fit in 130 px, because it just can't.
+ </td>
+ </tr>
+</table>
diff --git a/layout/tables/reftests/dynamic-text-overflow-table-cell.html b/layout/tables/reftests/dynamic-text-overflow-table-cell.html
new file mode 100644
index 0000000000..a572ebc77d
--- /dev/null
+++ b/layout/tables/reftests/dynamic-text-overflow-table-cell.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <table style="table-layout: fixed; width: 130px">
+ <tr>
+ <td style="overflow: hidden; white-space: nowrap;">
+ Some long text that cannot possibly fit in 130 px, because it just can't.
+ </td>
+ </tr>
+ </table>
+ <script>
+ onload = function() {
+ var td = document.querySelector("td");
+ // Make sure layout has happened.
+ var width = td.offsetWidth;
+ td.style.textOverflow = "ellipsis";
+ document.documentElement.className = "";
+ }
+ </script>
+</html>
diff --git a/layout/tables/reftests/reftest.list b/layout/tables/reftests/reftest.list
new file mode 100644
index 0000000000..15110c9853
--- /dev/null
+++ b/layout/tables/reftests/reftest.list
@@ -0,0 +1,14 @@
+== 1017137.html 1017137-ref.html
+== 1031934.html 1031934-ref.html
+== 1220621-1a.html 1220621-1-ref.html
+== 1220621-1b.html 1220621-1-ref.html
+== 1220621-1c.html 1220621-1-ref.html
+== 1220621-1d.html 1220621-1-ref.html
+== 1220621-1e.html 1220621-1-ref.html
+== 1220621-1f.html 1220621-1-ref.html
+== 1220621-2a.html 1220621-2-ref.html
+== 1220621-2b.html 1220621-2-ref.html
+== 1564308.html 1564308-ref.html
+== dynamic-text-overflow-table-cell.html dynamic-text-overflow-table-cell-ref.html
+!= dynamic-text-overflow-table-cell.html dynamic-text-overflow-table-cell-notref.html
+== dynamic-text-indent-table-cell.html dynamic-text-indent-table-cell-ref.html