summaryrefslogtreecommitdiffstats
path: root/accessible/tests/mochitest/textattrs/test_svg.html
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 /accessible/tests/mochitest/textattrs/test_svg.html
parentInitial commit. (diff)
downloadfirefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.tar.xz
firefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.zip
Adding upstream version 115.7.0esr.upstream/115.7.0esr
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'accessible/tests/mochitest/textattrs/test_svg.html')
-rw-r--r--accessible/tests/mochitest/textattrs/test_svg.html52
1 files changed, 52 insertions, 0 deletions
diff --git a/accessible/tests/mochitest/textattrs/test_svg.html b/accessible/tests/mochitest/textattrs/test_svg.html
new file mode 100644
index 0000000000..c8d5d5f893
--- /dev/null
+++ b/accessible/tests/mochitest/textattrs/test_svg.html
@@ -0,0 +1,52 @@
+<html>
+
+<head>
+ <title>SVG Text attributes tests</title>
+ <meta charset="utf-8">
+ <link rel="stylesheet" href="chrome://mochikit/content/tests/SimpleTest/test.css" />
+
+ <script src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script>
+
+ <script src="../common.js"></script>
+ <script src="../attributes.js"></script>
+ <script src="../events.js"></script>
+
+ <script>
+ function doTest() {
+ const svg = getNode("svg");
+ const defAttrs = buildDefaultTextAttrs(svg, "10pt");
+ testDefaultTextAttrs(svg, defAttrs);
+ testTextAttrs(svg, 0, {}, defAttrs, 0, 2);
+
+ const g = getNode("g");
+ testTextAttrs(g, 0, {}, defAttrs, 0, 2);
+
+ const a = getNode("a");
+ const aDefAttrs = buildDefaultTextAttrs(a, "10pt");
+ testTextAttrs(a, 0, {}, aDefAttrs, 0, 1);
+
+ SimpleTest.finish();
+ }
+
+ SimpleTest.waitForExplicitFinish();
+ addA11yLoadEvent(doTest);
+ </script>
+</head>
+<body style="font-size: 12pt">
+
+ <p id="display"></p>
+ <div id="content" style="display: none"></div>
+ <pre id="test">
+ </pre>
+
+ <svg id="svg" style="font-size: smaller">
+ <foreignobject>f1</foreignobject>
+ <g id="g">
+ <title>g</title>
+ <foreignobject>f2</foreignobject>
+ </g>
+ <text><a href="#" id="a">a</a></text>
+ </svg>
+
+</body>
+</html>