summaryrefslogtreecommitdiffstats
path: root/layout/reftests/w3c-css/submitted/text-decor-3
diff options
context:
space:
mode:
authorMatt A. Tobin <mattatobin@localhost.localdomain>2018-02-02 04:16:08 -0500
committerMatt A. Tobin <mattatobin@localhost.localdomain>2018-02-02 04:16:08 -0500
commit5f8de423f190bbb79a62f804151bc24824fa32d8 (patch)
tree10027f336435511475e392454359edea8e25895d /layout/reftests/w3c-css/submitted/text-decor-3
parent49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff)
downloadUXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip
Add m-esr52 at 52.6.0
Diffstat (limited to 'layout/reftests/w3c-css/submitted/text-decor-3')
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/reftest-stylo.list134
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/reftest.list131
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/ruby-text-decoration-01-ref.html27
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/ruby-text-decoration-01.html29
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-line-height-tests.py82
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-position-property-tests.py79
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-ruby-tests.py69
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-style-property-010-tests.sh81
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-style-property-tests.py85
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-decoration-propagation-01-ref.html9
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-decoration-propagation-01.html15
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-002-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-002.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001z.html18
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-002-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-002a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-002b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003c.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003d.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004c.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004d.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001c.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002c.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003c.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003d.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003e.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003f.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003g.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004c.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004d.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004e.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004f.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004g.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005c.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005d.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005e.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005f.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005g.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006c.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006d.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006e.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006f.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006g.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-001.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-002.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-003.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-003a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-003b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-004.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-004a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-001-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-001.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-002-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-002.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-003-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-003.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-003a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-004-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-004.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-004a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-001-ref.html7
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-001.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-002-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-002.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-003-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-003.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-004-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-004.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-005-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-005.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-005a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010-ref.html7
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Cc.html83
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Cf.html168
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Cn.html26
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Zl.html19
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Zp.html19
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Zs.html35
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012c.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-016-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-016.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-016a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017b.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-018-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-018.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-018a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-019-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-019.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-019a.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-020-ref.html8
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-020.html10
-rw-r--r--layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-020a.html10
152 files changed, 2383 insertions, 0 deletions
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/reftest-stylo.list b/layout/reftests/w3c-css/submitted/text-decor-3/reftest-stylo.list
new file mode 100644
index 000000000..7792a22e7
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/reftest-stylo.list
@@ -0,0 +1,134 @@
+# DO NOT EDIT! This is a auto-generated temporary list for Stylo testing
+
+
+== ruby-text-decoration-01.html ruby-text-decoration-01.html
+== text-decoration-propagation-01.html text-decoration-propagation-01.html
+
+# text-emphasis-style
+== text-emphasis-style-property-001.html text-emphasis-style-property-001.html
+fuzzy-if(gtkWidget,3,4) fuzzy-if(skiaContent,87,65) == text-emphasis-style-property-002.html text-emphasis-style-property-002.html
+skip-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == text-emphasis-style-property-003.html text-emphasis-style-property-003.html
+skip-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == text-emphasis-style-property-004.html text-emphasis-style-property-004.html
+== text-emphasis-style-property-005.html text-emphasis-style-property-005.html
+== text-emphasis-style-property-005a.html text-emphasis-style-property-005a.html
+# START tests from support/generate-text-emphasis-style-property-010-tests.sh
+== text-emphasis-style-property-010Zs.html text-emphasis-style-property-010Zs.html
+== text-emphasis-style-property-010Zl.html text-emphasis-style-property-010Zl.html
+== text-emphasis-style-property-010Zp.html text-emphasis-style-property-010Zp.html
+== text-emphasis-style-property-010Cc.html text-emphasis-style-property-010Cc.html
+fails fuzzy-if(skiaContent,1,336) == text-emphasis-style-property-010Cf.html text-emphasis-style-property-010Cf.html
+# END tests from support/generate-text-emphasis-style-property-010-tests.sh
+== text-emphasis-style-property-010Cn.html text-emphasis-style-property-010Cn.html
+# START tests from support/generate-text-emphasis-style-property-tests.py
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-011.html text-emphasis-style-property-011.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-011a.html text-emphasis-style-property-011a.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-011b.html text-emphasis-style-property-011b.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-012.html text-emphasis-style-property-012.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-012a.html text-emphasis-style-property-012a.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-012b.html text-emphasis-style-property-012b.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-012c.html text-emphasis-style-property-012c.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-013.html text-emphasis-style-property-013.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-013a.html text-emphasis-style-property-013a.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-013b.html text-emphasis-style-property-013b.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-014.html text-emphasis-style-property-014.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-014a.html text-emphasis-style-property-014a.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-014b.html text-emphasis-style-property-014b.html
+fails fuzzy-if(gtkWidget,3,4) skip-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == text-emphasis-style-property-015.html text-emphasis-style-property-015.html
+fails fuzzy-if(gtkWidget,3,4) skip-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == text-emphasis-style-property-015a.html text-emphasis-style-property-015a.html
+fails fuzzy-if(gtkWidget,3,4) skip-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == text-emphasis-style-property-015b.html text-emphasis-style-property-015b.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-016.html text-emphasis-style-property-016.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-016a.html text-emphasis-style-property-016a.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-017.html text-emphasis-style-property-017.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-017a.html text-emphasis-style-property-017a.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-017b.html text-emphasis-style-property-017b.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-018.html text-emphasis-style-property-018.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-018a.html text-emphasis-style-property-018a.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-019.html text-emphasis-style-property-019.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-019a.html text-emphasis-style-property-019a.html
+fails fuzzy-if(gtkWidget,3,4) skip-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == text-emphasis-style-property-020.html text-emphasis-style-property-020.html
+fails fuzzy-if(gtkWidget,3,4) skip-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == text-emphasis-style-property-020a.html text-emphasis-style-property-020a.html
+# END tests from support/generate-text-emphasis-style-property-tests.py
+
+# text-emphasis-color
+fuzzy-if(gtkWidget,3,4) == text-emphasis-color-property-001.html text-emphasis-color-property-001.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-color-property-001a.html text-emphasis-color-property-001a.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-color-property-002.html text-emphasis-color-property-002.html
+
+# text-emphasis
+== text-emphasis-property-001.html text-emphasis-property-001.html
+fuzzy-if(gtkWidget,3,4) fuzzy-if(skiaContent,87,65) == text-emphasis-property-002.html text-emphasis-property-002.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-property-003.html text-emphasis-property-003.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-property-003a.html text-emphasis-property-003a.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-property-003b.html text-emphasis-property-003b.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-property-004.html text-emphasis-property-004.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-property-004a.html text-emphasis-property-004a.html
+
+# text-emphasis-position
+# START tests from support/generate-text-emphasis-position-property-tests.py
+fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-001.html text-emphasis-position-property-001.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-001a.html text-emphasis-position-property-001a.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-001b.html text-emphasis-position-property-001b.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-001c.html text-emphasis-position-property-001c.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-002.html text-emphasis-position-property-002.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-002a.html text-emphasis-position-property-002a.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-002b.html text-emphasis-position-property-002b.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-002c.html text-emphasis-position-property-002c.html
+== text-emphasis-position-property-003.html text-emphasis-position-property-003.html
+== text-emphasis-position-property-003a.html text-emphasis-position-property-003a.html
+== text-emphasis-position-property-003b.html text-emphasis-position-property-003b.html
+== text-emphasis-position-property-003c.html text-emphasis-position-property-003c.html
+== text-emphasis-position-property-003d.html text-emphasis-position-property-003d.html
+== text-emphasis-position-property-003e.html text-emphasis-position-property-003e.html
+== text-emphasis-position-property-003f.html text-emphasis-position-property-003f.html
+== text-emphasis-position-property-003g.html text-emphasis-position-property-003g.html
+== text-emphasis-position-property-004.html text-emphasis-position-property-004.html
+== text-emphasis-position-property-004a.html text-emphasis-position-property-004a.html
+== text-emphasis-position-property-004b.html text-emphasis-position-property-004b.html
+== text-emphasis-position-property-004c.html text-emphasis-position-property-004c.html
+== text-emphasis-position-property-004d.html text-emphasis-position-property-004d.html
+== text-emphasis-position-property-004e.html text-emphasis-position-property-004e.html
+== text-emphasis-position-property-004f.html text-emphasis-position-property-004f.html
+== text-emphasis-position-property-004g.html text-emphasis-position-property-004g.html
+== text-emphasis-position-property-005.html text-emphasis-position-property-005.html
+== text-emphasis-position-property-005a.html text-emphasis-position-property-005a.html
+== text-emphasis-position-property-005b.html text-emphasis-position-property-005b.html
+== text-emphasis-position-property-005c.html text-emphasis-position-property-005c.html
+== text-emphasis-position-property-005d.html text-emphasis-position-property-005d.html
+== text-emphasis-position-property-005e.html text-emphasis-position-property-005e.html
+== text-emphasis-position-property-005f.html text-emphasis-position-property-005f.html
+== text-emphasis-position-property-005g.html text-emphasis-position-property-005g.html
+== text-emphasis-position-property-006.html text-emphasis-position-property-006.html
+== text-emphasis-position-property-006a.html text-emphasis-position-property-006a.html
+== text-emphasis-position-property-006b.html text-emphasis-position-property-006b.html
+== text-emphasis-position-property-006c.html text-emphasis-position-property-006c.html
+== text-emphasis-position-property-006d.html text-emphasis-position-property-006d.html
+== text-emphasis-position-property-006e.html text-emphasis-position-property-006e.html
+== text-emphasis-position-property-006f.html text-emphasis-position-property-006f.html
+== text-emphasis-position-property-006g.html text-emphasis-position-property-006g.html
+# END tests from support/generate-text-emphasis-position-property-tests.py
+
+# START tests from support/generate-text-emphasis-ruby-tests.py
+== text-emphasis-ruby-001.html text-emphasis-ruby-001.html
+== text-emphasis-ruby-002.html text-emphasis-ruby-002.html
+== text-emphasis-ruby-003.html text-emphasis-ruby-003.html
+== text-emphasis-ruby-003a.html text-emphasis-ruby-003a.html
+== text-emphasis-ruby-004.html text-emphasis-ruby-004.html
+== text-emphasis-ruby-004a.html text-emphasis-ruby-004a.html
+# END tests from support/generate-text-emphasis-ruby-tests.py
+
+# text-emphasis line height
+# START tests from support/generate-text-emphasis-line-height-tests.py
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-line-height-001a.html text-emphasis-line-height-001a.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-line-height-001b.html text-emphasis-line-height-001b.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-line-height-002a.html text-emphasis-line-height-002a.html
+fails fuzzy-if(gtkWidget,3,4) == text-emphasis-line-height-002b.html text-emphasis-line-height-002b.html
+== text-emphasis-line-height-003a.html text-emphasis-line-height-003a.html
+== text-emphasis-line-height-003b.html text-emphasis-line-height-003b.html
+== text-emphasis-line-height-003c.html text-emphasis-line-height-003c.html
+== text-emphasis-line-height-003d.html text-emphasis-line-height-003d.html
+== text-emphasis-line-height-004a.html text-emphasis-line-height-004a.html
+== text-emphasis-line-height-004b.html text-emphasis-line-height-004b.html
+== text-emphasis-line-height-004c.html text-emphasis-line-height-004c.html
+== text-emphasis-line-height-004d.html text-emphasis-line-height-004d.html
+# END tests from support/generate-text-emphasis-line-height-tests.py
+fails fuzzy-if(gtkWidget,3,4) fuzzy-if(/^Windows\x20NT\x2010\.0/.test(http.oscpu),43,1) == text-emphasis-line-height-001z.html text-emphasis-line-height-001z.html
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/reftest.list b/layout/reftests/w3c-css/submitted/text-decor-3/reftest.list
new file mode 100644
index 000000000..2c24653c6
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/reftest.list
@@ -0,0 +1,131 @@
+== ruby-text-decoration-01.html ruby-text-decoration-01-ref.html
+== text-decoration-propagation-01.html text-decoration-propagation-01-ref.html
+
+# text-emphasis-style
+== text-emphasis-style-property-001.html text-emphasis-style-property-001-ref.html
+fuzzy-if(gtkWidget,3,4) fuzzy-if(skiaContent,104,80) == text-emphasis-style-property-002.html text-emphasis-style-property-002-ref.html
+skip-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == text-emphasis-style-property-003.html text-emphasis-style-property-003-ref.html
+skip-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == text-emphasis-style-property-004.html text-emphasis-style-property-004-ref.html
+== text-emphasis-style-property-005.html text-emphasis-style-property-005-ref.html
+== text-emphasis-style-property-005a.html text-emphasis-style-property-005-ref.html
+# START tests from support/generate-text-emphasis-style-property-010-tests.sh
+== text-emphasis-style-property-010Zs.html text-emphasis-style-property-010-ref.html
+== text-emphasis-style-property-010Zl.html text-emphasis-style-property-010-ref.html
+== text-emphasis-style-property-010Zp.html text-emphasis-style-property-010-ref.html
+== text-emphasis-style-property-010Cc.html text-emphasis-style-property-010-ref.html
+fuzzy-if(skiaContent,1,336) == text-emphasis-style-property-010Cf.html text-emphasis-style-property-010-ref.html
+# END tests from support/generate-text-emphasis-style-property-010-tests.sh
+== text-emphasis-style-property-010Cn.html text-emphasis-style-property-010-ref.html
+# START tests from support/generate-text-emphasis-style-property-tests.py
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-011.html text-emphasis-style-property-011-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-011a.html text-emphasis-style-property-011-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-011b.html text-emphasis-style-property-011-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-012.html text-emphasis-style-property-012-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-012a.html text-emphasis-style-property-012-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-012b.html text-emphasis-style-property-012-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-012c.html text-emphasis-style-property-012-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-013.html text-emphasis-style-property-013-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-013a.html text-emphasis-style-property-013-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-013b.html text-emphasis-style-property-013-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-014.html text-emphasis-style-property-014-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-014a.html text-emphasis-style-property-014-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-014b.html text-emphasis-style-property-014-ref.html
+fuzzy-if(gtkWidget,3,4) skip-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == text-emphasis-style-property-015.html text-emphasis-style-property-015-ref.html
+fuzzy-if(gtkWidget,3,4) skip-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == text-emphasis-style-property-015a.html text-emphasis-style-property-015-ref.html
+fuzzy-if(gtkWidget,3,4) skip-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == text-emphasis-style-property-015b.html text-emphasis-style-property-015-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-016.html text-emphasis-style-property-016-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-016a.html text-emphasis-style-property-016-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-017.html text-emphasis-style-property-017-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-017a.html text-emphasis-style-property-017-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-017b.html text-emphasis-style-property-017-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-018.html text-emphasis-style-property-018-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-018a.html text-emphasis-style-property-018-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-019.html text-emphasis-style-property-019-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-style-property-019a.html text-emphasis-style-property-019-ref.html
+fuzzy-if(gtkWidget,3,4) skip-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == text-emphasis-style-property-020.html text-emphasis-style-property-020-ref.html
+fuzzy-if(gtkWidget,3,4) skip-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == text-emphasis-style-property-020a.html text-emphasis-style-property-020-ref.html
+# END tests from support/generate-text-emphasis-style-property-tests.py
+
+# text-emphasis-color
+fuzzy-if(gtkWidget,3,4) == text-emphasis-color-property-001.html text-emphasis-color-property-001-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-color-property-001a.html text-emphasis-color-property-001-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-color-property-002.html text-emphasis-color-property-002-ref.html
+
+# text-emphasis
+== text-emphasis-property-001.html text-emphasis-style-property-001-ref.html
+fuzzy-if(gtkWidget,3,4) fuzzy-if(skiaContent,104,80) == text-emphasis-property-002.html text-emphasis-style-property-002-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-property-003.html text-emphasis-style-property-012-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-property-003a.html text-emphasis-style-property-012-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-property-003b.html text-emphasis-style-property-012-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-property-004.html text-emphasis-color-property-002-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-property-004a.html text-emphasis-color-property-002-ref.html
+
+# text-emphasis-position
+# START tests from support/generate-text-emphasis-position-property-tests.py
+fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-001.html text-emphasis-position-property-001-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-001a.html text-emphasis-position-property-001-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-001b.html text-emphasis-position-property-001-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-001c.html text-emphasis-position-property-001-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-002.html text-emphasis-position-property-002-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-002a.html text-emphasis-position-property-002-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-002b.html text-emphasis-position-property-002-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-position-property-002c.html text-emphasis-position-property-002-ref.html
+== text-emphasis-position-property-003.html text-emphasis-position-property-003-ref.html
+== text-emphasis-position-property-003a.html text-emphasis-position-property-003-ref.html
+== text-emphasis-position-property-003b.html text-emphasis-position-property-003-ref.html
+== text-emphasis-position-property-003c.html text-emphasis-position-property-003-ref.html
+== text-emphasis-position-property-003d.html text-emphasis-position-property-003-ref.html
+== text-emphasis-position-property-003e.html text-emphasis-position-property-003-ref.html
+== text-emphasis-position-property-003f.html text-emphasis-position-property-003-ref.html
+== text-emphasis-position-property-003g.html text-emphasis-position-property-003-ref.html
+== text-emphasis-position-property-004.html text-emphasis-position-property-004-ref.html
+== text-emphasis-position-property-004a.html text-emphasis-position-property-004-ref.html
+== text-emphasis-position-property-004b.html text-emphasis-position-property-004-ref.html
+== text-emphasis-position-property-004c.html text-emphasis-position-property-004-ref.html
+== text-emphasis-position-property-004d.html text-emphasis-position-property-004-ref.html
+== text-emphasis-position-property-004e.html text-emphasis-position-property-004-ref.html
+== text-emphasis-position-property-004f.html text-emphasis-position-property-004-ref.html
+== text-emphasis-position-property-004g.html text-emphasis-position-property-004-ref.html
+== text-emphasis-position-property-005.html text-emphasis-position-property-005-ref.html
+== text-emphasis-position-property-005a.html text-emphasis-position-property-005-ref.html
+== text-emphasis-position-property-005b.html text-emphasis-position-property-005-ref.html
+== text-emphasis-position-property-005c.html text-emphasis-position-property-005-ref.html
+== text-emphasis-position-property-005d.html text-emphasis-position-property-005-ref.html
+== text-emphasis-position-property-005e.html text-emphasis-position-property-005-ref.html
+== text-emphasis-position-property-005f.html text-emphasis-position-property-005-ref.html
+== text-emphasis-position-property-005g.html text-emphasis-position-property-005-ref.html
+== text-emphasis-position-property-006.html text-emphasis-position-property-006-ref.html
+== text-emphasis-position-property-006a.html text-emphasis-position-property-006-ref.html
+== text-emphasis-position-property-006b.html text-emphasis-position-property-006-ref.html
+== text-emphasis-position-property-006c.html text-emphasis-position-property-006-ref.html
+== text-emphasis-position-property-006d.html text-emphasis-position-property-006-ref.html
+== text-emphasis-position-property-006e.html text-emphasis-position-property-006-ref.html
+== text-emphasis-position-property-006f.html text-emphasis-position-property-006-ref.html
+== text-emphasis-position-property-006g.html text-emphasis-position-property-006-ref.html
+# END tests from support/generate-text-emphasis-position-property-tests.py
+
+# START tests from support/generate-text-emphasis-ruby-tests.py
+== text-emphasis-ruby-001.html text-emphasis-ruby-001-ref.html
+== text-emphasis-ruby-002.html text-emphasis-ruby-002-ref.html
+== text-emphasis-ruby-003.html text-emphasis-ruby-003-ref.html
+== text-emphasis-ruby-003a.html text-emphasis-ruby-003-ref.html
+== text-emphasis-ruby-004.html text-emphasis-ruby-004-ref.html
+== text-emphasis-ruby-004a.html text-emphasis-ruby-004-ref.html
+# END tests from support/generate-text-emphasis-ruby-tests.py
+
+# text-emphasis line height
+# START tests from support/generate-text-emphasis-line-height-tests.py
+fuzzy-if(gtkWidget,3,4) == text-emphasis-line-height-001a.html text-emphasis-line-height-001-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-line-height-001b.html text-emphasis-line-height-001-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-line-height-002a.html text-emphasis-line-height-002-ref.html
+fuzzy-if(gtkWidget,3,4) == text-emphasis-line-height-002b.html text-emphasis-line-height-002-ref.html
+== text-emphasis-line-height-003a.html text-emphasis-line-height-003-ref.html
+== text-emphasis-line-height-003b.html text-emphasis-line-height-003-ref.html
+== text-emphasis-line-height-003c.html text-emphasis-line-height-003-ref.html
+== text-emphasis-line-height-003d.html text-emphasis-line-height-003-ref.html
+== text-emphasis-line-height-004a.html text-emphasis-line-height-004-ref.html
+== text-emphasis-line-height-004b.html text-emphasis-line-height-004-ref.html
+== text-emphasis-line-height-004c.html text-emphasis-line-height-004-ref.html
+== text-emphasis-line-height-004d.html text-emphasis-line-height-004-ref.html
+# END tests from support/generate-text-emphasis-line-height-tests.py
+fuzzy-if(gtkWidget,3,4) fuzzy-if(/^Windows\x20NT\x2010\.0/.test(http.oscpu),43,1) == text-emphasis-line-height-001z.html text-emphasis-line-height-001-ref.html
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/ruby-text-decoration-01-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/ruby-text-decoration-01-ref.html
new file mode 100644
index 000000000..c1b08d05c
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/ruby-text-decoration-01-ref.html
@@ -0,0 +1,27 @@
+<!DOCTYPE html>
+<html lang="ja">
+<head>
+ <meta charset="UTF-8">
+ <title>CSS Test: text-decoration on rubies</title>
+ <link rel="author" title="Xidorn Quan" href="http://www.upsuper.org/">
+</head>
+<style type="text/css">
+ ruby { display: ruby; }
+ rb { display: ruby-base; white-space: nowrap; }
+ rt { display: ruby-text; white-space: nowrap; }
+ p { line-height: 3em; }
+ span {
+ text-decoration: underline;
+ }
+</style>
+<body>
+ <p>
+ <ruby><rb><span>慶</span></rb><rt>けい</rt
+ ><rb><span>應</span></rb><rt>おう</rt
+ ><rb><span>義</span></rb><rt>ぎ</rt
+ ><rb><span>塾</span></rb><rt>じゅく</rt
+ ><rb><span>大</span></rb><rt>だい</rt
+ ><rb><span>学</span></rb><rt>がく</rt></ruby>
+ </p>
+</body>
+</html>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/ruby-text-decoration-01.html b/layout/reftests/w3c-css/submitted/text-decor-3/ruby-text-decoration-01.html
new file mode 100644
index 000000000..943581a92
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/ruby-text-decoration-01.html
@@ -0,0 +1,29 @@
+<!DOCTYPE html>
+<html lang="ja">
+<head>
+ <meta charset="UTF-8">
+ <title>CSS Test: text-decoration on rubies</title>
+ <link rel="author" title="Xidorn Quan" href="http://www.upsuper.org/">
+ <link rel="help" href="http://www.w3.org/TR/css-text-decor-3/#line-decoration">
+ <link rel="match" href="ruby-text-decoration-01-ref.html">
+</head>
+<style type="text/css">
+ ruby { display: ruby; }
+ rb { display: ruby-base; white-space: nowrap; }
+ rt { display: ruby-text; white-space: nowrap; }
+ p { line-height: 3em; }
+ p {
+ text-decoration: underline;
+ }
+</style>
+<body>
+ <p>
+ <ruby><rb>慶</rb><rt>けい</rt
+ ><rb>應</rb><rt>おう</rt
+ ><rb>義</rb><rt>ぎ</rt
+ ><rb>塾</rb><rt>じゅく</rt
+ ><rb>大</rb><rt>だい</rt
+ ><rb>学</rb><rt>がく</rt></ruby>
+ </p>
+</body>
+</html>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-line-height-tests.py b/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-line-height-tests.py
new file mode 100644
index 000000000..7aa975aaa
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-line-height-tests.py
@@ -0,0 +1,82 @@
+#!/usr/bin/env python
+# - * - coding: UTF-8 - * -
+
+"""
+This script generates tests text-emphasis-line-height-001 ~ 004 except
+001z. They test the line height expansion in different directions. This
+script outputs a list of all tests it generated in the format of Mozilla
+reftest.list to the stdout.
+"""
+
+from __future__ import unicode_literals
+
+TEST_FILE = 'text-emphasis-line-height-{:03}{}.html'
+TEST_TEMPLATE = '''<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis line height, {pos}, {wm}, {tag}</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="text emphasis marks should expand the line height like ruby if necessary">
+<link rel="match" href="text-emphasis-line-height-{index:03}-ref.html">
+<p>Pass if the emphasis marks are {dir} the black line:</p>
+{start}試験テスト{end}
+'''
+
+REF_FILE = 'text-emphasis-line-height-{:03}-ref.html'
+REF_TEMPLATE='''<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis line height, {pos}</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt {{ font-variant-east-asian: inherit; }} </style>
+<p>Pass if the emphasis marks are {dir} the black line:</p>
+<div style="line-height: 1; border-{pos}: 1px solid black; writing-mode: {wm}; ruby-position: {posval}"><ruby>試<rt>&#x25CF;</rt>験<rt>&#x25CF;</rt>テ<rt>&#x25CF;</rt>ス<rt>&#x25CF;</rt>ト<rt>&#x25CF;</rt></ruby></div>
+'''
+
+STYLE1 = 'line-height: 1; border-{pos}: 1px solid black; ' + \
+ 'writing-mode: {wm}; text-emphasis-position: {posval};'
+STYLE2 = 'text-emphasis: circle;'
+
+TAGS = [
+ # (tag, start, end)
+ ('div', '<div style="{style1}{style2}">', '</div>'),
+ ('span', '<div style="{style1}"><span style="{style2}">', '</span></div>'),
+ ]
+POSITIONS = [
+ # pos, text-emphasis-position, ruby-position,
+ # writing-modes, dir text
+ ('top', 'over right', 'over',
+ ['horizontal-tb'], 'below'),
+ ('bottom', 'under right', 'under',
+ ['horizontal-tb'], 'over'),
+ ('right', 'over right', 'over',
+ ['vertical-rl', 'vertical-lr'], 'to the left of'),
+ ('left', 'over left', 'under',
+ ['vertical-rl', 'vertical-lr'], 'to the right of'),
+ ]
+
+import string
+
+def write_file(filename, content):
+ with open(filename, 'wb') as f:
+ f.write(content.encode('UTF-8'))
+
+print("# START tests from {}".format(__file__))
+idx = 0
+for (pos, emphasis_pos, ruby_pos, wms, dir) in POSITIONS:
+ idx += 1
+ ref_file = REF_FILE.format(idx)
+ content = REF_TEMPLATE.format(pos=pos, dir=dir, wm=wms[0], posval=ruby_pos)
+ write_file(ref_file, content)
+ suffix = iter(string.ascii_lowercase)
+ for wm in wms:
+ style1 = STYLE1.format(pos=pos, wm=wm, posval=emphasis_pos)
+ for (tag, start, end) in TAGS:
+ test_file = TEST_FILE.format(idx, next(suffix))
+ content = TEST_TEMPLATE.format(
+ pos=pos, wm=wm, tag=tag, index=idx, dir=dir,
+ start=start.format(style1=style1, style2=STYLE2), end=end)
+ write_file(test_file, content)
+ print("== {} {}".format(test_file, ref_file))
+print("# END tests from {}".format(__file__))
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-position-property-tests.py b/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-position-property-tests.py
new file mode 100644
index 000000000..94701b57f
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-position-property-tests.py
@@ -0,0 +1,79 @@
+#!/usr/bin/env python
+# - * - coding: UTF-8 - * -
+
+"""
+This script generates tests text-emphasis-position-property-001 ~ 006
+which cover all possible values of text-emphasis-position property with
+all combination of three main writing modes and two orientations. Only
+test files are generated by this script. It also outputs a list of all
+tests it generated in the format of Mozilla reftest.list to the stdout.
+"""
+
+from __future__ import unicode_literals
+
+import itertools
+
+TEST_FILE = 'text-emphasis-position-property-{:03}{}.html'
+REF_FILE = 'text-emphasis-position-property-{:03}-ref.html'
+TEST_TEMPLATE = '''<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: {value}, {title}</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: {value}' with 'writing-mode: {wm}' puts emphasis marks {position} the text.">
+<link rel="match" href="text-emphasis-position-property-{index:03}-ref.html">
+<p>Pass if the emphasis marks are {position} the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: {wm}; text-orientation: {orient}; text-emphasis-position: {value}">試験テスト</div>
+'''
+
+SUFFIXES = ['', 'a', 'b', 'c', 'd', 'e', 'f', 'g']
+
+WRITING_MODES = ["horizontal-tb", "vertical-rl", "vertical-lr"]
+POSITION_HORIZONTAL = ["over", "under"]
+POSITION_VERTICAL = ["right", "left"]
+
+REF_MAP_MIXED = { "over": 1, "under": 2, "right": 3, "left": 4 }
+REF_MAP_SIDEWAYS = { "right": 5, "left": 6 }
+POSITION_TEXT = { "over": "over", "under": "under",
+ "right": "to the right of", "left": "to the left of" }
+
+suffixes = [iter(SUFFIXES) for i in range(6)]
+
+reftest_items = []
+
+def write_file(filename, content):
+ with open(filename, 'wb') as f:
+ f.write(content.encode('UTF-8'))
+
+def write_test_file(idx, suffix, wm, orient, value, position):
+ filename = TEST_FILE.format(idx, suffix)
+ write_file(filename, TEST_TEMPLATE.format(
+ value=value, wm=wm, orient=orient, index=idx, position=position,
+ title=(wm if orient == "mixed" else "{}, {}".format(wm, orient))))
+ reftest_items.append("== {} {}".format(filename, REF_FILE.format(idx)))
+
+def write_test_files(wm, orient, pos1, pos2):
+ idx = (REF_MAP_MIXED if orient == "mixed" else REF_MAP_SIDEWAYS)[pos1]
+ position = POSITION_TEXT[pos1]
+ suffix = suffixes[idx - 1]
+ write_test_file(idx, next(suffix), wm, orient, pos1 + " " + pos2, position)
+ write_test_file(idx, next(suffix), wm, orient, pos2 + " " + pos1, position)
+
+for wm in WRITING_MODES:
+ if wm == "horizontal-tb":
+ effective_pos = POSITION_HORIZONTAL
+ ineffective_pos = POSITION_VERTICAL
+ else:
+ effective_pos = POSITION_VERTICAL
+ ineffective_pos = POSITION_HORIZONTAL
+ for pos1, pos2 in itertools.product(effective_pos, ineffective_pos):
+ write_test_files(wm, "mixed", pos1, pos2)
+ if wm != "horizontal-tb":
+ write_test_files(wm, "sideways", pos1, pos2)
+
+print("# START tests from {}".format(__file__))
+reftest_items.sort()
+for item in reftest_items:
+ print(item)
+print("# END tests from {}".format(__file__))
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-ruby-tests.py b/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-ruby-tests.py
new file mode 100644
index 000000000..bb2f9706a
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-ruby-tests.py
@@ -0,0 +1,69 @@
+#!/usr/bin/env python
+# - * - coding: UTF-8 - * -
+
+"""
+This script generates tests text-emphasis-ruby-001 ~ 004 which tests
+emphasis marks with ruby in four directions. It outputs a list of all
+tests it generated in the format of Mozilla reftest.list to the stdout.
+"""
+
+from __future__ import unicode_literals
+
+TEST_FILE = 'text-emphasis-ruby-{:03}{}.html'
+TEST_TEMPLATE = '''<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis and ruby, {wm}, {pos}</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="emphasis marks are drawn outside the ruby">
+<link rel="match" href="text-emphasis-ruby-{index:03}-ref.html">
+<p>Pass if the emphasis marks are outside the ruby:</p>
+<div style="line-height: 5; writing-mode: {wm}; ruby-position: {ruby_pos}; text-emphasis-position: {posval}">ルビ<span style="text-emphasis: circle">と<ruby>圏<rt>けん</rt>点<rt>てん</rt></ruby>を</span>同時</div>
+'''
+
+REF_FILE = 'text-emphasis-ruby-{:03}-ref.html'
+REF_TEMPLATE = '''<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis and ruby, {wm}, {pos}</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rtc {{ font-variant-east-asian: inherit; }} </style>
+<p>Pass if the emphasis marks are outside the ruby:</p>
+<div style="line-height: 5; writing-mode: {wm}; ruby-position: {posval}">ルビ<ruby>と<rtc>&#x25CF;</rtc>圏<rt>けん</rt><rtc>&#x25CF;</rtc>点<rt>てん</rt><rtc>&#x25CF;</rtc>を<rtc>&#x25CF;</rtc></ruby>同時</div>
+'''
+
+TEST_CASES = [
+ ('top', 'horizontal-tb', 'over', [
+ ('horizontal-tb', 'over right')]),
+ ('bottom', 'horizontal-tb', 'under', [
+ ('horizontal-tb', 'under right')]),
+ ('right', 'vertical-rl', 'over', [
+ ('vertical-rl', 'over right'),
+ ('vertical-lr', 'over right')]),
+ ('left', 'vertical-rl', 'under', [
+ ('vertical-rl', 'over left'),
+ ('vertical-lr', 'over left')]),
+ ]
+
+SUFFIXES = ['', 'a']
+
+def write_file(filename, content):
+ with open(filename, 'wb') as f:
+ f.write(content.encode('UTF-8'))
+
+print("# START tests from {}".format(__file__))
+idx = 0
+for pos, ref_wm, ruby_pos, subtests in TEST_CASES:
+ idx += 1
+ ref_file = REF_FILE.format(idx)
+ ref_content = REF_TEMPLATE.format(pos=pos, wm=ref_wm, posval=ruby_pos)
+ write_file(ref_file, ref_content)
+ suffix = iter(SUFFIXES)
+ for wm, posval in subtests:
+ test_file = TEST_FILE.format(idx, next(suffix))
+ test_content = TEST_TEMPLATE.format(
+ wm=wm, pos=pos, index=idx, ruby_pos=ruby_pos, posval=posval)
+ write_file(test_file, test_content)
+ print("== {} {}".format(test_file, ref_file))
+print("# END tests from {}".format(__file__))
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-style-property-010-tests.sh b/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-style-property-010-tests.sh
new file mode 100644
index 000000000..3e5667429
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-style-property-010-tests.sh
@@ -0,0 +1,81 @@
+#!/usr/bin/env bash
+
+# This script generates tests text-emphasis-style-property-010* except
+# 010Cn. The tests generated cover all characters listed in the unicode
+# data file which should not have emphasis mark specified in the spec.
+# This script downloads UnicodeData.txt from the website of the Unicode
+# Consortium and extract the characters form that file. It requires
+# python (either 2.5+ or 3.x), awk, and wget to work. Only test files
+# are generated by this script. It also outputs a list of all tests it
+# generated in the format of Mozilla reftest.list to the stdout. Other
+# information has been redirected to the stderr.
+
+UNICODE_DATA_FILE='UnicodeData.txt'
+UNICODE_DATA_URL="http://www.unicode.org/Public/8.0.0/ucd/$UNICODE_DATA_FILE"
+UNICODE_DATA_DIGEST='38b17e1118206489a7e0ab5d29d7932212d38838df7d3ec025ecb58e8798ec20'
+
+TEST_FILE='text-emphasis-style-property-010%s.html'
+REF_FILE='text-emphasis-style-property-010-ref.html'
+
+digest_file() {
+ python -c "import hashlib;
+print(hashlib.sha256(open('$1', 'rb').read()).hexdigest())"
+}
+
+check_file() {
+ [[ -f "$UNICODE_DATA_FILE" ]] || return 1
+ digest=`digest_file "$UNICODE_DATA_FILE"`
+ [[ "$digest" == "$UNICODE_DATA_DIGEST" ]] || return 2
+}
+
+download_data() {
+ check_file
+ if [[ $? -eq 2 ]]; then
+ echo "Removing incorrect data file..." >&2
+ rm "$UNICODE_DATA_FILE"
+ fi
+ wget -nc -O"$UNICODE_DATA_FILE" "$UNICODE_DATA_URL" >&2
+
+ check_file
+ if [[ $? -ne 0 ]]; then
+ echo "Failed to get the correct unicode data file!" >&2
+ exit 1
+ fi
+}
+
+list_codepoints() {
+ awk -F';' "\$3 == \"$1\" { print \" 0x\"\$1\",\" }" "$UNICODE_DATA_FILE"
+}
+
+write_test_file() {
+ filename=`printf "$TEST_FILE" $1`
+ echo "== $filename $REF_FILE"
+ cat <<EOF > $filename
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis, $1</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="Emphasis marks should not be rendered for characters in general category $1">
+<link rel="match" href="text-emphasis-style-property-010-ref.html">
+<p>Pass if there is nothing rendered below:</p>
+<div style="color: white; white-space: pre-wrap; text-emphasis: filled circle red">
+<script>
+ var codepoints = [
+`list_codepoints "$1"`
+ ];
+ document.write(codepoints.map(function (code) {
+ return String.fromCodePoint(code);
+ }).join(' '));
+</script>
+</div>
+EOF
+}
+
+download_data
+echo "# START tests from $0"
+for c in Zs Zl Zp Cc Cf; do
+ write_test_file "$c"
+done
+echo "# END tests from $0"
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-style-property-tests.py b/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-style-property-tests.py
new file mode 100644
index 000000000..eb14e83bc
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/support/generate-text-emphasis-style-property-tests.py
@@ -0,0 +1,85 @@
+#!/usr/bin/env python
+# - * - coding: UTF-8 - * -
+
+"""
+This script generates tests text-emphasis-style-property-011 ~ 020 which
+cover all possible values of text-emphasis-style property, except none
+and <string>, with horizontal writing mode. It outputs a list of all
+tests it generated in the format of Mozilla reftest.list to the stdout.
+"""
+
+from __future__ import unicode_literals
+
+TEST_FILE = 'text-emphasis-style-property-{:03}{}.html'
+TEST_TEMPLATE = '''<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: {title}</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: {value}' produces {code} as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-{index:03}-ref.html">
+<p>Pass if there is a '{char}' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: {value}">試験テスト</div>
+'''
+
+REF_FILE = 'text-emphasis-style-property-{:03}-ref.html'
+REF_TEMPLATE = '''<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: {0}</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt {{ font-variant-east-asian: inherit; }} </style>
+<p>Pass if there is a '{1}' above every character below:</p>
+<div style="line-height: 5;"><ruby>試<rt>{1}</rt>験<rt>{1}</rt>テ<rt>{1}</rt>ス<rt>{1}</rt>ト<rt>{1}</rt></ruby></div>
+'''
+
+DATA_SET = [
+ ('dot', 0x2022, 0x25e6),
+ ('circle', 0x25cf, 0x25cb),
+ ('double-circle', 0x25c9, 0x25ce),
+ ('triangle', 0x25b2, 0x25b3),
+ ('sesame', 0xfe45, 0xfe46),
+ ]
+
+SUFFIXES = ['', 'a', 'b', 'c', 'd', 'e']
+
+def get_html_entity(code):
+ return '&#x{:04X};'.format(code)
+
+def write_file(filename, content):
+ with open(filename, 'wb') as f:
+ f.write(content.encode('UTF-8'))
+
+def write_test_file(idx, suffix, style, code, name=None):
+ if not name:
+ name = style
+ filename = TEST_FILE.format(idx, suffix)
+ write_file(filename, TEST_TEMPLATE.format(index=idx, value=style,
+ char=get_html_entity(code),
+ code='U+{:04X}'.format(code),
+ title=name))
+ print("== {} {}".format(filename, REF_FILE.format(idx)))
+
+idx = 10
+def write_files(style, code):
+ global idx
+ idx += 1
+ fill, shape = style
+ basic_style = "{} {}".format(fill, shape)
+ write_file(REF_FILE.format(idx),
+ REF_TEMPLATE.format(basic_style, get_html_entity(code)))
+ suffix = iter(SUFFIXES)
+ write_test_file(idx, next(suffix), basic_style, code)
+ write_test_file(idx, next(suffix), "{} {}".format(shape, fill), code)
+ if fill == 'filled':
+ write_test_file(idx, next(suffix), shape, code)
+ if shape == 'circle':
+ write_test_file(idx, next(suffix), fill, code, fill + ', horizontal')
+
+print("# START tests from {}".format(__file__))
+for name, code, _ in DATA_SET:
+ write_files(('filled', name), code)
+for name, _, code in DATA_SET:
+ write_files(('open', name), code)
+print("# END tests from {}".format(__file__))
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-decoration-propagation-01-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-decoration-propagation-01-ref.html
new file mode 100644
index 000000000..fe5b2191c
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-decoration-propagation-01-ref.html
@@ -0,0 +1,9 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test Reference</title>
+<link rel="author" title="Cameron McCormack" href="mailto:cam@mcc.id.au">
+<span>
+ <svg width="400" height="100">
+ <text x="10" y="30">This text must not be underlined.</text>
+ </svg>
+</span>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-decoration-propagation-01.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-decoration-propagation-01.html
new file mode 100644
index 000000000..45e680d4d
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-decoration-propagation-01.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-decoration shouldn't propagate through 'svg' element</title>
+<link rel="author" title="Cameron McCormack" href="mailto:cam@mcc.id.au">
+<link rel="help" href="http://www.w3.org/TR/css-text-decor-3/#line-decoration">
+<link rel="match" href="text-decoration-propagation-01-ref.html">
+<meta name="assert" content="An outer 'svg' element is an atomic inline-axis element, so text decorations must not propagate through it.">
+<style>
+span { text-decoration: underline; }
+</style>
+<span>
+ <svg width="400" height="100">
+ <text x="10" y="30">This text must not be underlined.</text>
+ </svg>
+</span>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001-ref.html
new file mode 100644
index 000000000..00c87eeb0
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-color: currentColor</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if there is a <strong>green</strong> '&#x25CF;' above every character below:</p>
+<div style="line-height: 5; color: green"><ruby>試<rt>&#x25CF;</rt>験<rt>&#x25CF;</rt>テ<rt>&#x25CF;</rt>ス<rt>&#x25CF;</rt>ト<rt>&#x25CF;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001.html
new file mode 100644
index 000000000..2d4676ad7
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-color: untouched</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-color-property">
+<meta name="assert" content="The color of emphasis marks should be the same as the text by default">
+<link rel="match" href="text-emphasis-color-property-001-ref.html">
+<p>Pass if there is a <strong>green</strong> '&#x25CF;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: filled circle; color: green">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001a.html
new file mode 100644
index 000000000..34c817e68
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-color: initial</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-color-property">
+<meta name="assert" content="The color of emphasis marks should be the same as the text for initial value">
+<link rel="match" href="text-emphasis-color-property-001-ref.html">
+<p>Pass if there is a <strong>green</strong> '&#x25CF;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: filled circle; text-emphasis-color: initial; color: green">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001b.html
new file mode 100644
index 000000000..0acb0f768
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-001b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-color: initial from text-emphasis</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-color-property">
+<meta name="assert" content="The color of emphasis marks should be the same as the text by default">
+<link rel="match" href="text-emphasis-color-property-001-ref.html">
+<p>Pass if there is a <strong>green</strong> '&#x25CF;' above every character below:</p>
+<div style="line-height: 5; text-emphasis: filled circle; color: green">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-002-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-002-ref.html
new file mode 100644
index 000000000..2bcc1d6b9
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-002-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-color: green</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; color: green; } </style>
+<p>Pass if there is a <strong>green</strong> '&#x25CF;' above every character below:</p>
+<div style="line-height: 5;"><ruby>試<rt>&#x25CF;</rt>験<rt>&#x25CF;</rt>テ<rt>&#x25CF;</rt>ス<rt>&#x25CF;</rt>ト<rt>&#x25CF;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-002.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-002.html
new file mode 100644
index 000000000..a215267eb
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-color-property-002.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-color: green</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-color-property">
+<meta name="assert" content="Emphasis marks should be rendered with color specified by text-emphasis-color.">
+<link rel="match" href="text-emphasis-color-property-002-ref.html">
+<p>Pass if there is a <strong>green</strong> '&#x25CF;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: filled circle; text-emphasis-color: green">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001-ref.html
new file mode 100644
index 000000000..682acb715
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis line height, top</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if the emphasis marks are below the black line:</p>
+<div style="line-height: 1; border-top: 1px solid black; writing-mode: horizontal-tb; ruby-position: over"><ruby>試<rt>&#x25CF;</rt>験<rt>&#x25CF;</rt>テ<rt>&#x25CF;</rt>ス<rt>&#x25CF;</rt>ト<rt>&#x25CF;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001a.html
new file mode 100644
index 000000000..933d4a427
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis line height, top, horizontal-tb, div</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="text emphasis marks should expand the line height like ruby if necessary">
+<link rel="match" href="text-emphasis-line-height-001-ref.html">
+<p>Pass if the emphasis marks are below the black line:</p>
+<div style="line-height: 1; border-top: 1px solid black; writing-mode: horizontal-tb; text-emphasis-position: over right;text-emphasis: circle;">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001b.html
new file mode 100644
index 000000000..58bf9821d
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis line height, top, horizontal-tb, span</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="text emphasis marks should expand the line height like ruby if necessary">
+<link rel="match" href="text-emphasis-line-height-001-ref.html">
+<p>Pass if the emphasis marks are below the black line:</p>
+<div style="line-height: 1; border-top: 1px solid black; writing-mode: horizontal-tb; text-emphasis-position: over right;"><span style="text-emphasis: circle;">試験テスト</span></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001z.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001z.html
new file mode 100644
index 000000000..ae6dfb588
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-001z.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis line height, top, textarea</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="text emphasis marks should expand the line height like ruby if necessary">
+<link rel="match" href="text-emphasis-line-height-001-ref.html">
+<style>
+textarea {
+ all: inherit;
+ width: 100%;
+ box-sizing: border-box;
+ border: 0 none; margin: 0; padding: 0;
+}
+</style>
+<p>Pass if the emphasis marks are below the black line:</p>
+<textarea style="line-height: 1; border-top: 1px solid black; text-emphasis: circle;">試験テスト</textarea>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-002-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-002-ref.html
new file mode 100644
index 000000000..345b1c146
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-002-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis line height, bottom</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if the emphasis marks are over the black line:</p>
+<div style="line-height: 1; border-bottom: 1px solid black; writing-mode: horizontal-tb; ruby-position: under"><ruby>試<rt>&#x25CF;</rt>験<rt>&#x25CF;</rt>テ<rt>&#x25CF;</rt>ス<rt>&#x25CF;</rt>ト<rt>&#x25CF;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-002a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-002a.html
new file mode 100644
index 000000000..eebe40d1f
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-002a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis line height, bottom, horizontal-tb, div</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="text emphasis marks should expand the line height like ruby if necessary">
+<link rel="match" href="text-emphasis-line-height-002-ref.html">
+<p>Pass if the emphasis marks are over the black line:</p>
+<div style="line-height: 1; border-bottom: 1px solid black; writing-mode: horizontal-tb; text-emphasis-position: under right;text-emphasis: circle;">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-002b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-002b.html
new file mode 100644
index 000000000..9f65d5f07
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-002b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis line height, bottom, horizontal-tb, span</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="text emphasis marks should expand the line height like ruby if necessary">
+<link rel="match" href="text-emphasis-line-height-002-ref.html">
+<p>Pass if the emphasis marks are over the black line:</p>
+<div style="line-height: 1; border-bottom: 1px solid black; writing-mode: horizontal-tb; text-emphasis-position: under right;"><span style="text-emphasis: circle;">試験テスト</span></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003-ref.html
new file mode 100644
index 000000000..a177e9b98
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis line height, right</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if the emphasis marks are to the left of the black line:</p>
+<div style="line-height: 1; border-right: 1px solid black; writing-mode: vertical-rl; ruby-position: over"><ruby>試<rt>&#x25CF;</rt>験<rt>&#x25CF;</rt>テ<rt>&#x25CF;</rt>ス<rt>&#x25CF;</rt>ト<rt>&#x25CF;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003a.html
new file mode 100644
index 000000000..4e60e5ad0
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis line height, right, vertical-rl, div</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="text emphasis marks should expand the line height like ruby if necessary">
+<link rel="match" href="text-emphasis-line-height-003-ref.html">
+<p>Pass if the emphasis marks are to the left of the black line:</p>
+<div style="line-height: 1; border-right: 1px solid black; writing-mode: vertical-rl; text-emphasis-position: over right;text-emphasis: circle;">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003b.html
new file mode 100644
index 000000000..01450b1e6
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis line height, right, vertical-rl, span</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="text emphasis marks should expand the line height like ruby if necessary">
+<link rel="match" href="text-emphasis-line-height-003-ref.html">
+<p>Pass if the emphasis marks are to the left of the black line:</p>
+<div style="line-height: 1; border-right: 1px solid black; writing-mode: vertical-rl; text-emphasis-position: over right;"><span style="text-emphasis: circle;">試験テスト</span></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003c.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003c.html
new file mode 100644
index 000000000..fde86c7fd
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003c.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis line height, right, vertical-lr, div</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="text emphasis marks should expand the line height like ruby if necessary">
+<link rel="match" href="text-emphasis-line-height-003-ref.html">
+<p>Pass if the emphasis marks are to the left of the black line:</p>
+<div style="line-height: 1; border-right: 1px solid black; writing-mode: vertical-lr; text-emphasis-position: over right;text-emphasis: circle;">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003d.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003d.html
new file mode 100644
index 000000000..78a3b1ea0
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-003d.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis line height, right, vertical-lr, span</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="text emphasis marks should expand the line height like ruby if necessary">
+<link rel="match" href="text-emphasis-line-height-003-ref.html">
+<p>Pass if the emphasis marks are to the left of the black line:</p>
+<div style="line-height: 1; border-right: 1px solid black; writing-mode: vertical-lr; text-emphasis-position: over right;"><span style="text-emphasis: circle;">試験テスト</span></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004-ref.html
new file mode 100644
index 000000000..e2a6a8c83
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis line height, left</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if the emphasis marks are to the right of the black line:</p>
+<div style="line-height: 1; border-left: 1px solid black; writing-mode: vertical-rl; ruby-position: under"><ruby>試<rt>&#x25CF;</rt>験<rt>&#x25CF;</rt>テ<rt>&#x25CF;</rt>ス<rt>&#x25CF;</rt>ト<rt>&#x25CF;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004a.html
new file mode 100644
index 000000000..0111f238c
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis line height, left, vertical-rl, div</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="text emphasis marks should expand the line height like ruby if necessary">
+<link rel="match" href="text-emphasis-line-height-004-ref.html">
+<p>Pass if the emphasis marks are to the right of the black line:</p>
+<div style="line-height: 1; border-left: 1px solid black; writing-mode: vertical-rl; text-emphasis-position: over left;text-emphasis: circle;">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004b.html
new file mode 100644
index 000000000..fbe45c04a
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis line height, left, vertical-rl, span</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="text emphasis marks should expand the line height like ruby if necessary">
+<link rel="match" href="text-emphasis-line-height-004-ref.html">
+<p>Pass if the emphasis marks are to the right of the black line:</p>
+<div style="line-height: 1; border-left: 1px solid black; writing-mode: vertical-rl; text-emphasis-position: over left;"><span style="text-emphasis: circle;">試験テスト</span></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004c.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004c.html
new file mode 100644
index 000000000..fa6786771
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004c.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis line height, left, vertical-lr, div</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="text emphasis marks should expand the line height like ruby if necessary">
+<link rel="match" href="text-emphasis-line-height-004-ref.html">
+<p>Pass if the emphasis marks are to the right of the black line:</p>
+<div style="line-height: 1; border-left: 1px solid black; writing-mode: vertical-lr; text-emphasis-position: over left;text-emphasis: circle;">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004d.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004d.html
new file mode 100644
index 000000000..2f5e0d404
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-line-height-004d.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis line height, left, vertical-lr, span</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="text emphasis marks should expand the line height like ruby if necessary">
+<link rel="match" href="text-emphasis-line-height-004-ref.html">
+<p>Pass if the emphasis marks are to the right of the black line:</p>
+<div style="line-height: 1; border-left: 1px solid black; writing-mode: vertical-lr; text-emphasis-position: over left;"><span style="text-emphasis: circle;">試験テスト</span></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001-ref.html
new file mode 100644
index 000000000..a401c67be
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-position: over</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if the emphasis marks are over the text below:</p>
+<div style="line-height: 5;"><ruby>試<rt>&#x25CF;</rt>験<rt>&#x25CF;</rt>テ<rt>&#x25CF;</rt>ス<rt>&#x25CF;</rt>ト<rt>&#x25CF;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001.html
new file mode 100644
index 000000000..feef0532c
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: over right, horizontal-tb</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: over right' with 'writing-mode: horizontal-tb' puts emphasis marks over the text.">
+<link rel="match" href="text-emphasis-position-property-001-ref.html">
+<p>Pass if the emphasis marks are over the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: horizontal-tb; text-orientation: mixed; text-emphasis-position: over right">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001a.html
new file mode 100644
index 000000000..731a04e11
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: right over, horizontal-tb</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: right over' with 'writing-mode: horizontal-tb' puts emphasis marks over the text.">
+<link rel="match" href="text-emphasis-position-property-001-ref.html">
+<p>Pass if the emphasis marks are over the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: horizontal-tb; text-orientation: mixed; text-emphasis-position: right over">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001b.html
new file mode 100644
index 000000000..36b8e455e
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: over left, horizontal-tb</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: over left' with 'writing-mode: horizontal-tb' puts emphasis marks over the text.">
+<link rel="match" href="text-emphasis-position-property-001-ref.html">
+<p>Pass if the emphasis marks are over the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: horizontal-tb; text-orientation: mixed; text-emphasis-position: over left">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001c.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001c.html
new file mode 100644
index 000000000..81cf7fd7c
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-001c.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: left over, horizontal-tb</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: left over' with 'writing-mode: horizontal-tb' puts emphasis marks over the text.">
+<link rel="match" href="text-emphasis-position-property-001-ref.html">
+<p>Pass if the emphasis marks are over the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: horizontal-tb; text-orientation: mixed; text-emphasis-position: left over">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002-ref.html
new file mode 100644
index 000000000..466594947
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-position: under</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if the emphasis marks are under the text below:</p>
+<div style="line-height: 5; ruby-position: under"><ruby>試<rt>&#x25CF;</rt>験<rt>&#x25CF;</rt>テ<rt>&#x25CF;</rt>ス<rt>&#x25CF;</rt>ト<rt>&#x25CF;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002.html
new file mode 100644
index 000000000..034a41ac8
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: under right, horizontal-tb</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: under right' with 'writing-mode: horizontal-tb' puts emphasis marks under the text.">
+<link rel="match" href="text-emphasis-position-property-002-ref.html">
+<p>Pass if the emphasis marks are under the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: horizontal-tb; text-orientation: mixed; text-emphasis-position: under right">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002a.html
new file mode 100644
index 000000000..4aae003b7
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: right under, horizontal-tb</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: right under' with 'writing-mode: horizontal-tb' puts emphasis marks under the text.">
+<link rel="match" href="text-emphasis-position-property-002-ref.html">
+<p>Pass if the emphasis marks are under the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: horizontal-tb; text-orientation: mixed; text-emphasis-position: right under">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002b.html
new file mode 100644
index 000000000..3ae17dcab
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: under left, horizontal-tb</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: under left' with 'writing-mode: horizontal-tb' puts emphasis marks under the text.">
+<link rel="match" href="text-emphasis-position-property-002-ref.html">
+<p>Pass if the emphasis marks are under the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: horizontal-tb; text-orientation: mixed; text-emphasis-position: under left">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002c.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002c.html
new file mode 100644
index 000000000..e67fce566
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-002c.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: left under, horizontal-tb</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: left under' with 'writing-mode: horizontal-tb' puts emphasis marks under the text.">
+<link rel="match" href="text-emphasis-position-property-002-ref.html">
+<p>Pass if the emphasis marks are under the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: horizontal-tb; text-orientation: mixed; text-emphasis-position: left under">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003-ref.html
new file mode 100644
index 000000000..770fa1e8f
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-position: right</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; writing-mode: vertical-rl; ruby-position: over"><ruby>試<rt>&#x25CF;</rt>験<rt>&#x25CF;</rt>テ<rt>&#x25CF;</rt>ス<rt>&#x25CF;</rt>ト<rt>&#x25CF;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003.html
new file mode 100644
index 000000000..b8fcd3d8d
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: right over, vertical-rl</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: right over' with 'writing-mode: vertical-rl' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-003-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: mixed; text-emphasis-position: right over">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003a.html
new file mode 100644
index 000000000..ded96690c
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: over right, vertical-rl</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: over right' with 'writing-mode: vertical-rl' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-003-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: mixed; text-emphasis-position: over right">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003b.html
new file mode 100644
index 000000000..25e69eb1d
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: right under, vertical-rl</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: right under' with 'writing-mode: vertical-rl' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-003-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: mixed; text-emphasis-position: right under">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003c.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003c.html
new file mode 100644
index 000000000..0cf05a3d4
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003c.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: under right, vertical-rl</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: under right' with 'writing-mode: vertical-rl' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-003-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: mixed; text-emphasis-position: under right">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003d.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003d.html
new file mode 100644
index 000000000..648721919
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003d.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: right over, vertical-lr</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: right over' with 'writing-mode: vertical-lr' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-003-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: mixed; text-emphasis-position: right over">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003e.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003e.html
new file mode 100644
index 000000000..b2dc58b2d
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003e.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: over right, vertical-lr</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: over right' with 'writing-mode: vertical-lr' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-003-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: mixed; text-emphasis-position: over right">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003f.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003f.html
new file mode 100644
index 000000000..ad2613bda
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003f.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: right under, vertical-lr</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: right under' with 'writing-mode: vertical-lr' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-003-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: mixed; text-emphasis-position: right under">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003g.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003g.html
new file mode 100644
index 000000000..c2cc3d6a8
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-003g.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: under right, vertical-lr</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: under right' with 'writing-mode: vertical-lr' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-003-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: mixed; text-emphasis-position: under right">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004-ref.html
new file mode 100644
index 000000000..1e56f5877
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-position: left</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; writing-mode: vertical-rl; ruby-position: under"><ruby>試<rt>&#x25CF;</rt>験<rt>&#x25CF;</rt>テ<rt>&#x25CF;</rt>ス<rt>&#x25CF;</rt>ト<rt>&#x25CF;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004.html
new file mode 100644
index 000000000..10a42ce81
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: left over, vertical-rl</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: left over' with 'writing-mode: vertical-rl' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-004-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: mixed; text-emphasis-position: left over">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004a.html
new file mode 100644
index 000000000..e1fc0a727
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: over left, vertical-rl</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: over left' with 'writing-mode: vertical-rl' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-004-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: mixed; text-emphasis-position: over left">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004b.html
new file mode 100644
index 000000000..2deb2e66a
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: left under, vertical-rl</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: left under' with 'writing-mode: vertical-rl' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-004-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: mixed; text-emphasis-position: left under">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004c.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004c.html
new file mode 100644
index 000000000..45b14882d
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004c.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: under left, vertical-rl</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: under left' with 'writing-mode: vertical-rl' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-004-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: mixed; text-emphasis-position: under left">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004d.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004d.html
new file mode 100644
index 000000000..2c0dd0234
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004d.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: left over, vertical-lr</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: left over' with 'writing-mode: vertical-lr' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-004-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: mixed; text-emphasis-position: left over">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004e.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004e.html
new file mode 100644
index 000000000..4b17e87c9
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004e.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: over left, vertical-lr</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: over left' with 'writing-mode: vertical-lr' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-004-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: mixed; text-emphasis-position: over left">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004f.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004f.html
new file mode 100644
index 000000000..1e7b48b56
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004f.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: left under, vertical-lr</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: left under' with 'writing-mode: vertical-lr' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-004-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: mixed; text-emphasis-position: left under">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004g.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004g.html
new file mode 100644
index 000000000..02860e4fb
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-004g.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: under left, vertical-lr</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: under left' with 'writing-mode: vertical-lr' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-004-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: mixed; text-emphasis-position: under left">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005-ref.html
new file mode 100644
index 000000000..7427dec9d
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-position: right, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; writing-mode: vertical-rl; text-orientation: sideways; ruby-position: over"><ruby>試<rt>&#x25CF;</rt>験<rt>&#x25CF;</rt>テ<rt>&#x25CF;</rt>ス<rt>&#x25CF;</rt>ト<rt>&#x25CF;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005.html
new file mode 100644
index 000000000..2eaca9cf0
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: right over, vertical-rl, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: right over' with 'writing-mode: vertical-rl' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-005-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: sideways; text-emphasis-position: right over">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005a.html
new file mode 100644
index 000000000..1061e936f
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: over right, vertical-rl, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: over right' with 'writing-mode: vertical-rl' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-005-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: sideways; text-emphasis-position: over right">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005b.html
new file mode 100644
index 000000000..f535eb2bc
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: right under, vertical-rl, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: right under' with 'writing-mode: vertical-rl' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-005-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: sideways; text-emphasis-position: right under">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005c.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005c.html
new file mode 100644
index 000000000..111804711
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005c.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: under right, vertical-rl, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: under right' with 'writing-mode: vertical-rl' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-005-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: sideways; text-emphasis-position: under right">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005d.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005d.html
new file mode 100644
index 000000000..390446cdf
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005d.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: right over, vertical-lr, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: right over' with 'writing-mode: vertical-lr' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-005-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: sideways; text-emphasis-position: right over">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005e.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005e.html
new file mode 100644
index 000000000..6f65274d0
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005e.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: over right, vertical-lr, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: over right' with 'writing-mode: vertical-lr' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-005-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: sideways; text-emphasis-position: over right">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005f.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005f.html
new file mode 100644
index 000000000..ecec98122
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005f.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: right under, vertical-lr, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: right under' with 'writing-mode: vertical-lr' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-005-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: sideways; text-emphasis-position: right under">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005g.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005g.html
new file mode 100644
index 000000000..81b220bff
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-005g.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: under right, vertical-lr, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: under right' with 'writing-mode: vertical-lr' puts emphasis marks to the right of the text.">
+<link rel="match" href="text-emphasis-position-property-005-ref.html">
+<p>Pass if the emphasis marks are to the right of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: sideways; text-emphasis-position: under right">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006-ref.html
new file mode 100644
index 000000000..85af6c250
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-position: left, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; writing-mode: vertical-rl; text-orientation: sideways; ruby-position: under"><ruby>試<rt>&#x25CF;</rt>験<rt>&#x25CF;</rt>テ<rt>&#x25CF;</rt>ス<rt>&#x25CF;</rt>ト<rt>&#x25CF;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006.html
new file mode 100644
index 000000000..8933513b7
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: left over, vertical-rl, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: left over' with 'writing-mode: vertical-rl' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-006-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: sideways; text-emphasis-position: left over">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006a.html
new file mode 100644
index 000000000..5aa8067f5
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: over left, vertical-rl, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: over left' with 'writing-mode: vertical-rl' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-006-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: sideways; text-emphasis-position: over left">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006b.html
new file mode 100644
index 000000000..6d98ea15f
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: left under, vertical-rl, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: left under' with 'writing-mode: vertical-rl' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-006-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: sideways; text-emphasis-position: left under">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006c.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006c.html
new file mode 100644
index 000000000..1d1acd964
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006c.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: under left, vertical-rl, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: under left' with 'writing-mode: vertical-rl' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-006-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-rl; text-orientation: sideways; text-emphasis-position: under left">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006d.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006d.html
new file mode 100644
index 000000000..575f07d5f
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006d.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: left over, vertical-lr, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: left over' with 'writing-mode: vertical-lr' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-006-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: sideways; text-emphasis-position: left over">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006e.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006e.html
new file mode 100644
index 000000000..d03a66cc2
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006e.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: over left, vertical-lr, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: over left' with 'writing-mode: vertical-lr' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-006-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: sideways; text-emphasis-position: over left">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006f.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006f.html
new file mode 100644
index 000000000..955a5e212
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006f.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: left under, vertical-lr, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: left under' with 'writing-mode: vertical-lr' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-006-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: sideways; text-emphasis-position: left under">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006g.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006g.html
new file mode 100644
index 000000000..9f21cc5c9
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-position-property-006g.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-position: under left, vertical-lr, sideways</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="'text-emphasis-position: under left' with 'writing-mode: vertical-lr' puts emphasis marks to the left of the text.">
+<link rel="match" href="text-emphasis-position-property-006-ref.html">
+<p>Pass if the emphasis marks are to the left of the text below:</p>
+<div style="line-height: 5; text-emphasis: circle; writing-mode: vertical-lr; text-orientation: sideways; text-emphasis-position: under left">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-001.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-001.html
new file mode 100644
index 000000000..f45e2add8
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-001.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis: none</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-property">
+<meta name="assert" content="text-emphasis: none does not produce any emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-001-ref.html">
+<p>Pass if there is NO emphasis marks above the text below:</p>
+<div style="line-height: 5; text-emphasis: none">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-002.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-002.html
new file mode 100644
index 000000000..0083d3e7a
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-002.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis: string</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-property">
+<meta name="assert" content="'text-emphasis: string' uses the given string as emphasis marks">
+<link rel="match" href="text-emphasis-style-property-002-ref.html">
+<p>Pass if there is a '^' above every character below:</p>
+<div style="line-height: 5; text-emphasis: '^'">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-003.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-003.html
new file mode 100644
index 000000000..fc35010e3
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-003.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis: circle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-property">
+<meta name="assert" content="'text-emphasis: circle' produces U+25CF as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-012-ref.html">
+<p>Pass if there is a '&#x25CF;' above every character below:</p>
+<div style="line-height: 5; text-emphasis: circle">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-003a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-003a.html
new file mode 100644
index 000000000..e70518b06
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-003a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis: filled</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-property">
+<meta name="assert" content="'text-emphasis: filled' produces U+25CF as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-012-ref.html">
+<p>Pass if there is a '&#x25CF;' above every character below:</p>
+<div style="line-height: 5; text-emphasis: filled">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-003b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-003b.html
new file mode 100644
index 000000000..79e66bc93
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-003b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis: filled circle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-property">
+<meta name="assert" content="'text-emphasis: filled circle' produces U+25CF as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-012-ref.html">
+<p>Pass if there is a '&#x25CF;' above every character below:</p>
+<div style="line-height: 5; text-emphasis: filled circle">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-004.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-004.html
new file mode 100644
index 000000000..15d2ab001
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-004.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis: circle green</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-property">
+<meta name="assert" content="Emphasis marks should be rendered with color specified by text-emphasis.">
+<link rel="match" href="text-emphasis-color-property-002-ref.html">
+<p>Pass if there is a <strong>green</strong> '&#x25CF;' above every character below:</p>
+<div style="line-height: 5; text-emphasis: circle green">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-004a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-004a.html
new file mode 100644
index 000000000..6d0d80d29
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-property-004a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis: green circle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-property">
+<meta name="assert" content="Emphasis marks should be rendered with color specified by text-emphasis.">
+<link rel="match" href="text-emphasis-color-property-002-ref.html">
+<p>Pass if there is a <strong>green</strong> '&#x25CF;' above every character below:</p>
+<div style="line-height: 5; text-emphasis: green circle">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-001-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-001-ref.html
new file mode 100644
index 000000000..e48967f9f
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-001-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis and ruby, horizontal-tb, top</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rtc { font-variant-east-asian: inherit; } </style>
+<p>Pass if the emphasis marks are outside the ruby:</p>
+<div style="line-height: 5; writing-mode: horizontal-tb; ruby-position: over">ルビ<ruby>と<rtc>&#x25CF;</rtc>圏<rt>けん</rt><rtc>&#x25CF;</rtc>点<rt>てん</rt><rtc>&#x25CF;</rtc>を<rtc>&#x25CF;</rtc></ruby>同時</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-001.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-001.html
new file mode 100644
index 000000000..61c47aa0b
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-001.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis and ruby, horizontal-tb, top</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="emphasis marks are drawn outside the ruby">
+<link rel="match" href="text-emphasis-ruby-001-ref.html">
+<p>Pass if the emphasis marks are outside the ruby:</p>
+<div style="line-height: 5; writing-mode: horizontal-tb; ruby-position: over; text-emphasis-position: over right">ルビ<span style="text-emphasis: circle">と<ruby>圏<rt>けん</rt>点<rt>てん</rt></ruby>を</span>同時</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-002-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-002-ref.html
new file mode 100644
index 000000000..ca2c0cc6f
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-002-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis and ruby, horizontal-tb, bottom</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rtc { font-variant-east-asian: inherit; } </style>
+<p>Pass if the emphasis marks are outside the ruby:</p>
+<div style="line-height: 5; writing-mode: horizontal-tb; ruby-position: under">ルビ<ruby>と<rtc>&#x25CF;</rtc>圏<rt>けん</rt><rtc>&#x25CF;</rtc>点<rt>てん</rt><rtc>&#x25CF;</rtc>を<rtc>&#x25CF;</rtc></ruby>同時</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-002.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-002.html
new file mode 100644
index 000000000..47fcfe19f
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-002.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis and ruby, horizontal-tb, bottom</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="emphasis marks are drawn outside the ruby">
+<link rel="match" href="text-emphasis-ruby-002-ref.html">
+<p>Pass if the emphasis marks are outside the ruby:</p>
+<div style="line-height: 5; writing-mode: horizontal-tb; ruby-position: under; text-emphasis-position: under right">ルビ<span style="text-emphasis: circle">と<ruby>圏<rt>けん</rt>点<rt>てん</rt></ruby>を</span>同時</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-003-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-003-ref.html
new file mode 100644
index 000000000..182037b0d
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-003-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis and ruby, vertical-rl, right</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rtc { font-variant-east-asian: inherit; } </style>
+<p>Pass if the emphasis marks are outside the ruby:</p>
+<div style="line-height: 5; writing-mode: vertical-rl; ruby-position: over">ルビ<ruby>と<rtc>&#x25CF;</rtc>圏<rt>けん</rt><rtc>&#x25CF;</rtc>点<rt>てん</rt><rtc>&#x25CF;</rtc>を<rtc>&#x25CF;</rtc></ruby>同時</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-003.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-003.html
new file mode 100644
index 000000000..f3cff064f
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-003.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis and ruby, vertical-rl, right</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="emphasis marks are drawn outside the ruby">
+<link rel="match" href="text-emphasis-ruby-003-ref.html">
+<p>Pass if the emphasis marks are outside the ruby:</p>
+<div style="line-height: 5; writing-mode: vertical-rl; ruby-position: over; text-emphasis-position: over right">ルビ<span style="text-emphasis: circle">と<ruby>圏<rt>けん</rt>点<rt>てん</rt></ruby>を</span>同時</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-003a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-003a.html
new file mode 100644
index 000000000..8dbb5a0a4
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-003a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis and ruby, vertical-lr, right</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="emphasis marks are drawn outside the ruby">
+<link rel="match" href="text-emphasis-ruby-003-ref.html">
+<p>Pass if the emphasis marks are outside the ruby:</p>
+<div style="line-height: 5; writing-mode: vertical-lr; ruby-position: over; text-emphasis-position: over right">ルビ<span style="text-emphasis: circle">と<ruby>圏<rt>けん</rt>点<rt>てん</rt></ruby>を</span>同時</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-004-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-004-ref.html
new file mode 100644
index 000000000..44bcba492
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-004-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis and ruby, vertical-rl, left</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rtc { font-variant-east-asian: inherit; } </style>
+<p>Pass if the emphasis marks are outside the ruby:</p>
+<div style="line-height: 5; writing-mode: vertical-rl; ruby-position: under">ルビ<ruby>と<rtc>&#x25CF;</rtc>圏<rt>けん</rt><rtc>&#x25CF;</rtc>点<rt>てん</rt><rtc>&#x25CF;</rtc>を<rtc>&#x25CF;</rtc></ruby>同時</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-004.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-004.html
new file mode 100644
index 000000000..f95fd809a
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-004.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis and ruby, vertical-rl, left</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="emphasis marks are drawn outside the ruby">
+<link rel="match" href="text-emphasis-ruby-004-ref.html">
+<p>Pass if the emphasis marks are outside the ruby:</p>
+<div style="line-height: 5; writing-mode: vertical-rl; ruby-position: under; text-emphasis-position: over left">ルビ<span style="text-emphasis: circle">と<ruby>圏<rt>けん</rt>点<rt>てん</rt></ruby>を</span>同時</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-004a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-004a.html
new file mode 100644
index 000000000..cf0ba4c4a
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-ruby-004a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis and ruby, vertical-lr, left</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-position-property">
+<meta name="assert" content="emphasis marks are drawn outside the ruby">
+<link rel="match" href="text-emphasis-ruby-004-ref.html">
+<p>Pass if the emphasis marks are outside the ruby:</p>
+<div style="line-height: 5; writing-mode: vertical-lr; ruby-position: under; text-emphasis-position: over left">ルビ<span style="text-emphasis: circle">と<ruby>圏<rt>けん</rt>点<rt>てん</rt></ruby>を</span>同時</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-001-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-001-ref.html
new file mode 100644
index 000000000..60f8fa7b9
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-001-ref.html
@@ -0,0 +1,7 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: none</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<p>Pass if there is NO emphasis marks above the text below:</p>
+<div style="line-height: 5;">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-001.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-001.html
new file mode 100644
index 000000000..910293b44
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-001.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: none</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="text-emphasis-style: none does not produce any emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-001-ref.html">
+<p>Pass if there is NO emphasis marks above the text below:</p>
+<div style="line-height: 5; text-emphasis-style: none">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-002-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-002-ref.html
new file mode 100644
index 000000000..e9cf74415
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-002-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: string</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: normal; } </style>
+<p>Pass if there is a '^' above every character below:</p>
+<div style="line-height: 5"><ruby>試<rt>^</rt>験<rt>^</rt>テ<rt>^</rt>ス<rt>^</rt>ト<rt>^</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-002.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-002.html
new file mode 100644
index 000000000..dc0496653
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-002.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: string</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: string' uses the given string as emphasis marks">
+<link rel="match" href="text-emphasis-style-property-002-ref.html">
+<p>Pass if there is a '^' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: '^'">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-003-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-003-ref.html
new file mode 100644
index 000000000..d9c29d749
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-003-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: filled sesame, vertical</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: normal; } </style>
+<p>Pass if there is a '&#xFE45;' to the right of every character below:</p>
+<div style="writing-mode: vertical-rl; line-height: 5;"><ruby>試<rt>&#xFE45;</rt>験<rt>&#xFE45;</rt>テ<rt>&#xFE45;</rt>ス<rt>&#xFE45;</rt>ト<rt>&#xFE45;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-003.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-003.html
new file mode 100644
index 000000000..b2af7448f
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-003.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: filled, vertical</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: filled' produces U+FE45 as emphasis marks in vertical writing modes.">
+<link rel="match" href="text-emphasis-style-property-003-ref.html">
+<p>Pass if there is a '&#xFE45;' to the right of every character below:</p>
+<div style="writing-mode: vertical-rl; line-height: 5; text-emphasis-style: filled">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-004-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-004-ref.html
new file mode 100644
index 000000000..a1065f419
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-004-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: open sesame, vertical</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: normal; } </style>
+<p>Pass if there is a '&#xFE46;' to the right of every character below:</p>
+<div style="writing-mode: vertical-rl; line-height: 5;"><ruby>試<rt>&#xFE46;</rt>験<rt>&#xFE46;</rt>テ<rt>&#xFE46;</rt>ス<rt>&#xFE46;</rt>ト<rt>&#xFE46;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-004.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-004.html
new file mode 100644
index 000000000..60c718653
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-004.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: open, vertical</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis: open sesame' produces U+FE46 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-004-ref.html">
+<p>Pass if there is a '&#xFE46;' to the right of every character below:</p>
+<div style="writing-mode: vertical-rl; line-height: 5; text-emphasis-style: open">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-005-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-005-ref.html
new file mode 100644
index 000000000..b65490267
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-005-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style, vertical</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: normal; text-orientation: upright; } </style>
+<p>Pass if the emphasis marks 'V' are upright:</p>
+<div style="writing-mode: vertical-rl; line-height: 5;"><ruby>試<rt>V</rt>験<rt>V</rt>テ<rt>V</rt>ス<rt>V</rt>ト<rt>V</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-005.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-005.html
new file mode 100644
index 000000000..29be3abda
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-005.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style, vertical-rl</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="Emphasis marks must remain upright in vertical writing modes">
+<link rel="match" href="text-emphasis-style-property-005-ref.html">
+<p>Pass if the emphasis marks 'V' are upright:</p>
+<div style="writing-mode: vertical-rl; line-height: 5; text-emphasis-style: 'V'">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-005a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-005a.html
new file mode 100644
index 000000000..af0ad4e0a
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-005a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style, vertical-lr</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="Emphasis marks must remain upright in vertical writing modes">
+<link rel="match" href="text-emphasis-style-property-005-ref.html">
+<p>Pass if the emphasis marks 'V' are upright:</p>
+<div style="writing-mode: vertical-lr; line-height: 5; text-emphasis-style: 'V'">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010-ref.html
new file mode 100644
index 000000000..93028d6e7
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010-ref.html
@@ -0,0 +1,7 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis on characters without emphasis mark</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<p>Pass if there is nothing rendered below:</p>
+<div></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Cc.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Cc.html
new file mode 100644
index 000000000..78ded1ca2
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Cc.html
@@ -0,0 +1,83 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis, Cc</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="Emphasis marks should not be rendered for characters in general category Cc">
+<link rel="match" href="text-emphasis-style-property-010-ref.html">
+<p>Pass if there is nothing rendered below:</p>
+<div style="color: white; white-space: pre-wrap; text-emphasis: filled circle red">
+<script>
+ var codepoints = [
+ 0x0000,
+ 0x0001,
+ 0x0002,
+ 0x0003,
+ 0x0004,
+ 0x0005,
+ 0x0006,
+ 0x0007,
+ 0x0008,
+ 0x0009,
+ 0x000A,
+ 0x000B,
+ 0x000C,
+ 0x000D,
+ 0x000E,
+ 0x000F,
+ 0x0010,
+ 0x0011,
+ 0x0012,
+ 0x0013,
+ 0x0014,
+ 0x0015,
+ 0x0016,
+ 0x0017,
+ 0x0018,
+ 0x0019,
+ 0x001A,
+ 0x001B,
+ 0x001C,
+ 0x001D,
+ 0x001E,
+ 0x001F,
+ 0x007F,
+ 0x0080,
+ 0x0081,
+ 0x0082,
+ 0x0083,
+ 0x0084,
+ 0x0085,
+ 0x0086,
+ 0x0087,
+ 0x0088,
+ 0x0089,
+ 0x008A,
+ 0x008B,
+ 0x008C,
+ 0x008D,
+ 0x008E,
+ 0x008F,
+ 0x0090,
+ 0x0091,
+ 0x0092,
+ 0x0093,
+ 0x0094,
+ 0x0095,
+ 0x0096,
+ 0x0097,
+ 0x0098,
+ 0x0099,
+ 0x009A,
+ 0x009B,
+ 0x009C,
+ 0x009D,
+ 0x009E,
+ 0x009F,
+ ];
+ document.write(codepoints.map(function (code) {
+ return String.fromCodePoint(code);
+ }).join(' '));
+</script>
+</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Cf.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Cf.html
new file mode 100644
index 000000000..012ef3785
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Cf.html
@@ -0,0 +1,168 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis, Cf</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="Emphasis marks should not be rendered for characters in general category Cf">
+<link rel="match" href="text-emphasis-style-property-010-ref.html">
+<p>Pass if there is nothing rendered below:</p>
+<div style="color: white; white-space: pre-wrap; text-emphasis: filled circle red">
+<script>
+ var codepoints = [
+ 0x00AD,
+ 0x0600,
+ 0x0601,
+ 0x0602,
+ 0x0603,
+ 0x0604,
+ 0x0605,
+ 0x061C,
+ 0x06DD,
+ 0x070F,
+ 0x180E,
+ 0x200B,
+ 0x200C,
+ 0x200D,
+ 0x200E,
+ 0x200F,
+ 0x202A,
+ 0x202B,
+ 0x202C,
+ 0x202D,
+ 0x202E,
+ 0x2060,
+ 0x2061,
+ 0x2062,
+ 0x2063,
+ 0x2064,
+ 0x2066,
+ 0x2067,
+ 0x2068,
+ 0x2069,
+ 0x206A,
+ 0x206B,
+ 0x206C,
+ 0x206D,
+ 0x206E,
+ 0x206F,
+ 0xFEFF,
+ 0xFFF9,
+ 0xFFFA,
+ 0xFFFB,
+ 0x110BD,
+ 0x1BCA0,
+ 0x1BCA1,
+ 0x1BCA2,
+ 0x1BCA3,
+ 0x1D173,
+ 0x1D174,
+ 0x1D175,
+ 0x1D176,
+ 0x1D177,
+ 0x1D178,
+ 0x1D179,
+ 0x1D17A,
+ 0xE0001,
+ 0xE0020,
+ 0xE0021,
+ 0xE0022,
+ 0xE0023,
+ 0xE0024,
+ 0xE0025,
+ 0xE0026,
+ 0xE0027,
+ 0xE0028,
+ 0xE0029,
+ 0xE002A,
+ 0xE002B,
+ 0xE002C,
+ 0xE002D,
+ 0xE002E,
+ 0xE002F,
+ 0xE0030,
+ 0xE0031,
+ 0xE0032,
+ 0xE0033,
+ 0xE0034,
+ 0xE0035,
+ 0xE0036,
+ 0xE0037,
+ 0xE0038,
+ 0xE0039,
+ 0xE003A,
+ 0xE003B,
+ 0xE003C,
+ 0xE003D,
+ 0xE003E,
+ 0xE003F,
+ 0xE0040,
+ 0xE0041,
+ 0xE0042,
+ 0xE0043,
+ 0xE0044,
+ 0xE0045,
+ 0xE0046,
+ 0xE0047,
+ 0xE0048,
+ 0xE0049,
+ 0xE004A,
+ 0xE004B,
+ 0xE004C,
+ 0xE004D,
+ 0xE004E,
+ 0xE004F,
+ 0xE0050,
+ 0xE0051,
+ 0xE0052,
+ 0xE0053,
+ 0xE0054,
+ 0xE0055,
+ 0xE0056,
+ 0xE0057,
+ 0xE0058,
+ 0xE0059,
+ 0xE005A,
+ 0xE005B,
+ 0xE005C,
+ 0xE005D,
+ 0xE005E,
+ 0xE005F,
+ 0xE0060,
+ 0xE0061,
+ 0xE0062,
+ 0xE0063,
+ 0xE0064,
+ 0xE0065,
+ 0xE0066,
+ 0xE0067,
+ 0xE0068,
+ 0xE0069,
+ 0xE006A,
+ 0xE006B,
+ 0xE006C,
+ 0xE006D,
+ 0xE006E,
+ 0xE006F,
+ 0xE0070,
+ 0xE0071,
+ 0xE0072,
+ 0xE0073,
+ 0xE0074,
+ 0xE0075,
+ 0xE0076,
+ 0xE0077,
+ 0xE0078,
+ 0xE0079,
+ 0xE007A,
+ 0xE007B,
+ 0xE007C,
+ 0xE007D,
+ 0xE007E,
+ 0xE007F,
+ ];
+ document.write(codepoints.map(function (code) {
+ return String.fromCodePoint(code);
+ }).join(' '));
+</script>
+</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Cn.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Cn.html
new file mode 100644
index 000000000..90f583df3
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Cn.html
@@ -0,0 +1,26 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis, Cn</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="Emphasis marks should not be rendered for non-characters">
+<link rel="match" href="text-emphasis-style-property-010-ref.html">
+<p>Pass if there is nothing rendered below:</p>
+<div style="color: white; white-space: pre-wrap; text-emphasis: filled circle red">
+<script>
+ // U+FDD0..U+FDEF and U+XXFFFE..U+XXFFFF are noncharacters,
+ // and thus guaranteed to be unassigned.
+ var codepoints = [];
+ for (var code = 0xFDD0; code <= 0xFDEF; ++code) {
+ codepoints.push(code);
+ }
+ for (var plane = 0; plane <= 0x10; ++plane) {
+ codepoints.push(plane * 0x10000 + 0xFFFE);
+ codepoints.push(plane * 0x10000 + 0xFFFF);
+ }
+ document.write(codepoints.map(function (code) {
+ return String.fromCodePoint(code);
+ }).join(' '));
+</script>
+</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Zl.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Zl.html
new file mode 100644
index 000000000..38840ba38
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Zl.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis, Zl</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="Emphasis marks should not be rendered for characters in general category Zl">
+<link rel="match" href="text-emphasis-style-property-010-ref.html">
+<p>Pass if there is nothing rendered below:</p>
+<div style="color: white; white-space: pre-wrap; text-emphasis: filled circle red">
+<script>
+ var codepoints = [
+ 0x2028,
+ ];
+ document.write(codepoints.map(function (code) {
+ return String.fromCodePoint(code);
+ }).join(' '));
+</script>
+</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Zp.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Zp.html
new file mode 100644
index 000000000..f0bbdbc8a
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Zp.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis, Zp</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="Emphasis marks should not be rendered for characters in general category Zp">
+<link rel="match" href="text-emphasis-style-property-010-ref.html">
+<p>Pass if there is nothing rendered below:</p>
+<div style="color: white; white-space: pre-wrap; text-emphasis: filled circle red">
+<script>
+ var codepoints = [
+ 0x2029,
+ ];
+ document.write(codepoints.map(function (code) {
+ return String.fromCodePoint(code);
+ }).join(' '));
+</script>
+</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Zs.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Zs.html
new file mode 100644
index 000000000..c6e415252
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-010Zs.html
@@ -0,0 +1,35 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis, Zs</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="Emphasis marks should not be rendered for characters in general category Zs">
+<link rel="match" href="text-emphasis-style-property-010-ref.html">
+<p>Pass if there is nothing rendered below:</p>
+<div style="color: white; white-space: pre-wrap; text-emphasis: filled circle red">
+<script>
+ var codepoints = [
+ 0x0020,
+ 0x00A0,
+ 0x1680,
+ 0x2000,
+ 0x2001,
+ 0x2002,
+ 0x2003,
+ 0x2004,
+ 0x2005,
+ 0x2006,
+ 0x2007,
+ 0x2008,
+ 0x2009,
+ 0x200A,
+ 0x202F,
+ 0x205F,
+ 0x3000,
+ ];
+ document.write(codepoints.map(function (code) {
+ return String.fromCodePoint(code);
+ }).join(' '));
+</script>
+</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011-ref.html
new file mode 100644
index 000000000..9f28f3f41
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: filled dot</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if there is a '&#x2022;' above every character below:</p>
+<div style="line-height: 5;"><ruby>試<rt>&#x2022;</rt>験<rt>&#x2022;</rt>テ<rt>&#x2022;</rt>ス<rt>&#x2022;</rt>ト<rt>&#x2022;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011.html
new file mode 100644
index 000000000..ed8d0fd4e
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: filled dot</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: filled dot' produces U+2022 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-011-ref.html">
+<p>Pass if there is a '&#x2022;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: filled dot">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011a.html
new file mode 100644
index 000000000..849280198
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: dot filled</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: dot filled' produces U+2022 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-011-ref.html">
+<p>Pass if there is a '&#x2022;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: dot filled">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011b.html
new file mode 100644
index 000000000..894b57e24
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-011b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: dot</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: dot' produces U+2022 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-011-ref.html">
+<p>Pass if there is a '&#x2022;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: dot">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012-ref.html
new file mode 100644
index 000000000..672a659f4
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: filled circle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if there is a '&#x25CF;' above every character below:</p>
+<div style="line-height: 5;"><ruby>試<rt>&#x25CF;</rt>験<rt>&#x25CF;</rt>テ<rt>&#x25CF;</rt>ス<rt>&#x25CF;</rt>ト<rt>&#x25CF;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012.html
new file mode 100644
index 000000000..97c8dfde0
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: filled circle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: filled circle' produces U+25CF as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-012-ref.html">
+<p>Pass if there is a '&#x25CF;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: filled circle">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012a.html
new file mode 100644
index 000000000..5aa13441c
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: circle filled</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: circle filled' produces U+25CF as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-012-ref.html">
+<p>Pass if there is a '&#x25CF;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: circle filled">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012b.html
new file mode 100644
index 000000000..a9ece184d
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: circle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: circle' produces U+25CF as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-012-ref.html">
+<p>Pass if there is a '&#x25CF;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: circle">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012c.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012c.html
new file mode 100644
index 000000000..624473247
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-012c.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: filled, horizontal</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: filled' produces U+25CF as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-012-ref.html">
+<p>Pass if there is a '&#x25CF;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: filled">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013-ref.html
new file mode 100644
index 000000000..5d6cb187d
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: filled double-circle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if there is a '&#x25C9;' above every character below:</p>
+<div style="line-height: 5;"><ruby>試<rt>&#x25C9;</rt>験<rt>&#x25C9;</rt>テ<rt>&#x25C9;</rt>ス<rt>&#x25C9;</rt>ト<rt>&#x25C9;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013.html
new file mode 100644
index 000000000..074ef47f1
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: filled double-circle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: filled double-circle' produces U+25C9 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-013-ref.html">
+<p>Pass if there is a '&#x25C9;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: filled double-circle">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013a.html
new file mode 100644
index 000000000..b641c21e5
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: double-circle filled</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: double-circle filled' produces U+25C9 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-013-ref.html">
+<p>Pass if there is a '&#x25C9;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: double-circle filled">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013b.html
new file mode 100644
index 000000000..2f68d4484
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-013b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: double-circle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: double-circle' produces U+25C9 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-013-ref.html">
+<p>Pass if there is a '&#x25C9;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: double-circle">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014-ref.html
new file mode 100644
index 000000000..a18fc957b
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: filled triangle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if there is a '&#x25B2;' above every character below:</p>
+<div style="line-height: 5;"><ruby>試<rt>&#x25B2;</rt>験<rt>&#x25B2;</rt>テ<rt>&#x25B2;</rt>ス<rt>&#x25B2;</rt>ト<rt>&#x25B2;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014.html
new file mode 100644
index 000000000..60231abf9
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: filled triangle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: filled triangle' produces U+25B2 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-014-ref.html">
+<p>Pass if there is a '&#x25B2;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: filled triangle">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014a.html
new file mode 100644
index 000000000..1c72bda80
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: triangle filled</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: triangle filled' produces U+25B2 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-014-ref.html">
+<p>Pass if there is a '&#x25B2;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: triangle filled">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014b.html
new file mode 100644
index 000000000..9b32cdd67
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-014b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: triangle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: triangle' produces U+25B2 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-014-ref.html">
+<p>Pass if there is a '&#x25B2;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: triangle">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015-ref.html
new file mode 100644
index 000000000..a9cef72d3
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: filled sesame</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if there is a '&#xFE45;' above every character below:</p>
+<div style="line-height: 5;"><ruby>試<rt>&#xFE45;</rt>験<rt>&#xFE45;</rt>テ<rt>&#xFE45;</rt>ス<rt>&#xFE45;</rt>ト<rt>&#xFE45;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015.html
new file mode 100644
index 000000000..6c62462ad
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: filled sesame</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: filled sesame' produces U+FE45 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-015-ref.html">
+<p>Pass if there is a '&#xFE45;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: filled sesame">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015a.html
new file mode 100644
index 000000000..e059497b0
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: sesame filled</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: sesame filled' produces U+FE45 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-015-ref.html">
+<p>Pass if there is a '&#xFE45;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: sesame filled">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015b.html
new file mode 100644
index 000000000..a243600b0
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-015b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: sesame</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: sesame' produces U+FE45 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-015-ref.html">
+<p>Pass if there is a '&#xFE45;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: sesame">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-016-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-016-ref.html
new file mode 100644
index 000000000..6b104021b
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-016-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: open dot</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if there is a '&#x25E6;' above every character below:</p>
+<div style="line-height: 5;"><ruby>試<rt>&#x25E6;</rt>験<rt>&#x25E6;</rt>テ<rt>&#x25E6;</rt>ス<rt>&#x25E6;</rt>ト<rt>&#x25E6;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-016.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-016.html
new file mode 100644
index 000000000..954f9f4e8
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-016.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: open dot</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: open dot' produces U+25E6 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-016-ref.html">
+<p>Pass if there is a '&#x25E6;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: open dot">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-016a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-016a.html
new file mode 100644
index 000000000..aeabcfa70
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-016a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: dot open</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: dot open' produces U+25E6 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-016-ref.html">
+<p>Pass if there is a '&#x25E6;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: dot open">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017-ref.html
new file mode 100644
index 000000000..c0be7ffd8
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: open circle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if there is a '&#x25CB;' above every character below:</p>
+<div style="line-height: 5;"><ruby>試<rt>&#x25CB;</rt>験<rt>&#x25CB;</rt>テ<rt>&#x25CB;</rt>ス<rt>&#x25CB;</rt>ト<rt>&#x25CB;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017.html
new file mode 100644
index 000000000..948ccf083
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: open circle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: open circle' produces U+25CB as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-017-ref.html">
+<p>Pass if there is a '&#x25CB;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: open circle">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017a.html
new file mode 100644
index 000000000..b9f58a888
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: circle open</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: circle open' produces U+25CB as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-017-ref.html">
+<p>Pass if there is a '&#x25CB;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: circle open">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017b.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017b.html
new file mode 100644
index 000000000..19ae3c8cb
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-017b.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: open, horizontal</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: open' produces U+25CB as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-017-ref.html">
+<p>Pass if there is a '&#x25CB;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: open">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-018-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-018-ref.html
new file mode 100644
index 000000000..f9d2980a8
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-018-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: open double-circle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if there is a '&#x25CE;' above every character below:</p>
+<div style="line-height: 5;"><ruby>試<rt>&#x25CE;</rt>験<rt>&#x25CE;</rt>テ<rt>&#x25CE;</rt>ス<rt>&#x25CE;</rt>ト<rt>&#x25CE;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-018.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-018.html
new file mode 100644
index 000000000..30713e614
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-018.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: open double-circle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: open double-circle' produces U+25CE as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-018-ref.html">
+<p>Pass if there is a '&#x25CE;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: open double-circle">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-018a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-018a.html
new file mode 100644
index 000000000..b3e577df1
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-018a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: double-circle open</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: double-circle open' produces U+25CE as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-018-ref.html">
+<p>Pass if there is a '&#x25CE;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: double-circle open">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-019-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-019-ref.html
new file mode 100644
index 000000000..b8f4f201f
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-019-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: open triangle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if there is a '&#x25B3;' above every character below:</p>
+<div style="line-height: 5;"><ruby>試<rt>&#x25B3;</rt>験<rt>&#x25B3;</rt>テ<rt>&#x25B3;</rt>ス<rt>&#x25B3;</rt>ト<rt>&#x25B3;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-019.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-019.html
new file mode 100644
index 000000000..20c8069ec
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-019.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: open triangle</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: open triangle' produces U+25B3 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-019-ref.html">
+<p>Pass if there is a '&#x25B3;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: open triangle">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-019a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-019a.html
new file mode 100644
index 000000000..f73bf2111
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-019a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: triangle open</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: triangle open' produces U+25B3 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-019-ref.html">
+<p>Pass if there is a '&#x25B3;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: triangle open">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-020-ref.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-020-ref.html
new file mode 100644
index 000000000..1502d3d7f
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-020-ref.html
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reference: text-emphasis-style: open sesame</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<style> rt { font-variant-east-asian: inherit; } </style>
+<p>Pass if there is a '&#xFE46;' above every character below:</p>
+<div style="line-height: 5;"><ruby>試<rt>&#xFE46;</rt>験<rt>&#xFE46;</rt>テ<rt>&#xFE46;</rt>ス<rt>&#xFE46;</rt>ト<rt>&#xFE46;</rt></ruby></div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-020.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-020.html
new file mode 100644
index 000000000..09c5ae534
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-020.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: open sesame</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: open sesame' produces U+FE46 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-020-ref.html">
+<p>Pass if there is a '&#xFE46;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: open sesame">試験テスト</div>
diff --git a/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-020a.html b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-020a.html
new file mode 100644
index 000000000..a32781d61
--- /dev/null
+++ b/layout/reftests/w3c-css/submitted/text-decor-3/text-emphasis-style-property-020a.html
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: text-emphasis-style: sesame open</title>
+<link rel="author" title="Xidorn Quan" href="https://www.upsuper.org">
+<link rel="author" title="Mozilla" href="https://www.mozilla.org">
+<link rel="help" href="https://drafts.csswg.org/css-text-decor-3/#text-emphasis-style-property">
+<meta name="assert" content="'text-emphasis-style: sesame open' produces U+FE46 as emphasis marks.">
+<link rel="match" href="text-emphasis-style-property-020-ref.html">
+<p>Pass if there is a '&#xFE46;' above every character below:</p>
+<div style="line-height: 5; text-emphasis-style: sesame open">試験テスト</div>