summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/css/CSS2/margin-padding-clear
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 00:47:55 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 00:47:55 +0000
commit26a029d407be480d791972afb5975cf62c9360a6 (patch)
treef435a8308119effd964b339f76abb83a57c29483 /testing/web-platform/tests/css/CSS2/margin-padding-clear
parentInitial commit. (diff)
downloadfirefox-26a029d407be480d791972afb5975cf62c9360a6.tar.xz
firefox-26a029d407be480d791972afb5975cf62c9360a6.zip
Adding upstream version 124.0.1.upstream/124.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'testing/web-platform/tests/css/CSS2/margin-padding-clear')
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-001-ref.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-001.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-002-ref.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-002.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-003-ref.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-003.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-004-ref.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-004.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-005-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-005.xht58
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-006-ref.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-006.xht56
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-007-ref.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-007.xht56
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-008-ref.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-008.xht56
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-009-ref.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-009.xht56
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-001-ref.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-001.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-002.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-003.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-004.xht46
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-005.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-006.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-007.xht46
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-008.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-009-ref.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-009.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-010.xht32
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-012.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-013.xht47
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-014.xht48
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-015.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-auto-on-block-box-ref.html54
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-auto-on-block-box.html78
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-backgrounds-001.xht26
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-backgrounds-002.xht58
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-backgrounds-003.xht47
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-001-ref.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-001.xht47
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-002.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-003.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-004.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-005.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-006.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-007-ref.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-007.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-008.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-016.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-017.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-018.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-019-ref.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-019.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-020.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-028.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-029.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-030.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-031-ref.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-031.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-032.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-040.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-041.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-042.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-043-ref.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-043.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-044.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-052.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-053.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-054.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-055.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-056.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-064.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-065.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-066.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-067-ref.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-067.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-068.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-076.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-077.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-078.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-079-ref.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-079.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-080.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-088.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-089.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-090.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-091-ref.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-091.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-092.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-100-ref.xht33
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-100.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-101.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-102.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-103-ref.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-103.xht43
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-104.xht43
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-109.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-110.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-111.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-112.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-113.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-001-ref.xht39
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-001.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-002.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-003.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-004.xht46
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-005.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-006.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-007.xht46
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-008-ref.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-008.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-009-ref.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-009.xht31
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-010.xht32
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-012.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-013.xht46
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-014.xht47
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-015.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-001-ref.xht48
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-001.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-002-ref.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-002.xht46
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-003-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-003.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-004-ref.xht31
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-004.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-005.xht48
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-006.xht47
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-007.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-008.xht48
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-009.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-010-ref.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-010.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-011.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-012.xht44
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-013-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-013.xht47
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-014.xht47
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-015.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-015a.xht66
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-016.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-017-ref.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-017.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-019.xht55
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-020-ref.xht31
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-020.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-021.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-022.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-025.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-026.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-028.xht60
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-029.xht48
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-030.xht46
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-032.xht56
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-037-ref.xht32
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-037.xht56
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-038-ref.xht32
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-038.xht73
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-039.xht90
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-040.xht101
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-041.xht107
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-101-ref.xht62
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-101.xht46
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-102.xht27
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-103-ref.xht31
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-103.xht26
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-104.xht27
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-105.xht47
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-106-ref.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-106.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-107.xht53
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-108.xht53
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-109.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-110-ref.xht48
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-110.xht62
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-111.xht63
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-112.xht48
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-113-ref.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-113.xht58
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-114-ref.xht53
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-114.xht60
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-115-ref.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-115.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-116.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-117.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-118.xht44
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-119.xht56
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-120.xht56
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-126.xht21
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-127.xht23
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-128.xht33
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-129.xht33
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-130-ref.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-130.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-131-ref.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-131.xht27
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-132.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-133.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-137-ref.xht31
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-137.xht32
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-138.xht32
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-139.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-140.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-141.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-143.xht31
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-145.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-146.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-147.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-148.xht54
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-151.xht22
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-154.xht98
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-155-ref.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-155.xht93
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-156-ref.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-156.xht44
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-159-ref.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-159.xht47
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-160.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-162.xht33
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-163.xht32
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-000.xht32
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-001.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-004.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-006.xht33
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-007.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-010.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-001-ref.xht17
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-001.xht27
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-002-ref.xht22
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-002.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-em-inherit-001-ref.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-em-inherit-001.xht97
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-001-ref.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-001.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-002-ref.xht26
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-002.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-004-ref.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-004.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-005.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-006.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-007-ref.xht28
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-007.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-008.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-016.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-017.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-018.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-019-ref.xht28
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-019.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-020.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-028.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-029.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-030.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-031-ref.xht28
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-031.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-032.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-040.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-041.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-042.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-043-ref.xht28
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-043.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-044.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-052.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-053.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-054.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-055.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-056.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-064.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-065.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-066.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-067-ref.xht28
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-067.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-068.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-076.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-077.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-078.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-079-ref.xht28
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-079.xht44
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-080.xht43
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-088.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-089.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-090.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-091.xht43
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-092.xht43
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-100.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-101.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-102.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-103-ref.xht28
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-103.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-104.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-109.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-110.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-111.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-112.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-113-ref.xht31
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-113.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-001-ref.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-001.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-002.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-003.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-004.xht44
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-005.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-006.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-007.xht44
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-008.xht32
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-009-ref.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-009.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-010.xht33
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-012.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-013.xht44
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-014.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-015.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-percentage-inherit-001-ref.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-percentage-inherit-001.xht95
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-percentage-undefined-001.xht26
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-004.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-005.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-006.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-007.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-008.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-016.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-017.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-018.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-019.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-020.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-028.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-029.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-030.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-031.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-032.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-040.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-041.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-042.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-043.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-044.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-052.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-053.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-054.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-055.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-056.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-064.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-065.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-066.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-067.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-068.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-076.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-077.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-078.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-079.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-080.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-088.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-089.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-090.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-091.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-092.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-100-ref.xht32
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-100.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-101.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-102.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-103-ref.xht31
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-103.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-104.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-109.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-110.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-111.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-112.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-113-ref.xht31
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-113.xht43
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-001.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-002.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-003.xht53
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-004.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-005.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-006.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-007.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-008.xht32
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-009.xht33
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-010.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-012.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-013.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-014.xht46
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-015.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-001-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-001.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-002-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-002.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-003-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-003.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-004.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-004.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-005.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-006.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-007-ref.xht24
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-007.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-008.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-016.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-017.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-018.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-019-ref.xht24
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-019.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-020.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-028.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-029.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-030.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-031-ref.xht24
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-031.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-032.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-040.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-041.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-042.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-043-ref.xht24
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-043.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-044.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-052.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-053.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-054.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-055.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-056.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-064.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-065.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-066.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-067-ref.xht24
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-067.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-068.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-076.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-077.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-078.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-079-ref.xht24
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-079.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-080.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-088.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-089.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-090.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-091.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-092.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-100.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-101.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-102.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-103-ref.xht28
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-103.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-104.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-109.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-110.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-111.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-112.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-113-ref.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-113.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-001-ref.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-001.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-002.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-003.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-004.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-005.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-006.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-007.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-008.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-009.xht31
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-010.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-012-ref.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-012.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-013-ref.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-013.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-014.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-015.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-001.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-002.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-003.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-004-ref.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-004.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-005-ref.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-005.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-006-ref.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-006.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-007-ref.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-007.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-008-ref.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-008.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-009-ref.xht22
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-009.xht24
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-001.xht53
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-002.xht53
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-003.xht53
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-004.xht47
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-005.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-006.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-007.xht47
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-008.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-009.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-010.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-012.xht33
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-013.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-014.xht45
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-015.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-016.xht32
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-017.xht31
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-background-001-ref.xht28
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-background-001.xht23
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-001.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-002.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-003.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-004.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-005.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-006.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-007.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-012.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-013.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-014.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-015.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-016.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-017.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-018.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-023.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-024.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-025.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-026.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-027.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-028.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-029.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-034.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-035.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-036.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-037.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-038.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-039.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-040.xht31
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-045.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-046.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-047.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-048.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-049.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-050.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-051.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-056.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-057.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-058.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-059.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-060.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-061.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-062.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-067.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-068.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-069.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-070.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-071.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-072.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-073.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-078.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-079.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-080.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-081.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-082.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-083.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-084.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-089.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-090.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-091-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-091.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-092.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-093.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-094.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-095.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-100.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-101.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-102.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-103-ref.xht24
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-103.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-001-ref.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-001.xht55
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-002.xht55
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-003.xht56
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-004.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-005.xht54
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-006.xht54
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-007-ref.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-007.xht44
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-008.xht33
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-009.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-010.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-012.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-013.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-014.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-015.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-em-inherit-001-ref.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-em-inherit-001.xht101
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-001.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-002.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-003.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-004.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-005.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-006.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-007.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-012.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-013.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-015.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-016.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-017.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-018.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-023.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-024.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-025.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-026.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-027.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-028.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-029.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-034.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-035.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-036-ref.xht16
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-036.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-037.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-038.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-039.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-040.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-045.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-046.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-047-ref.xht16
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-047.xht52
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-048.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-049.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-050.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-051.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-056.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-057.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-058.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-059.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-060.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-061.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-062.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-067.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-068.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-069.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-070.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-071.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-072.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-073.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-078.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-079.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-080.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-081.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-082.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-083.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-084.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-089.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-090.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-091-ref.xht28
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-091.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-092.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-093.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-094.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-095.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-100.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-101.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-102.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-103-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-103.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-001.xht55
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-002.xht55
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-003.xht55
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-004.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-005.xht54
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-006.xht54
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-007.xht44
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-008-ref.xht15
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-008.xht33
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-009.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-010-ref.xht16
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-010.xht39
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-012.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-013.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-014.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-015.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-percentage-inherit-001-ref.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-percentage-inherit-001.xht96
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-percentage-undefined-001.xht26
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-001.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-002.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-003-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-003.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-004.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-005.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-006-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-006.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-007.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-012.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-013.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-015.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-016.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-017-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-017.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-018.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-023.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-024.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-025-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-025.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-026.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-027.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-028-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-028.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-029.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-034.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-035.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-036.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-037.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-038.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-039-ref.xht31
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-039.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-040.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-045.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-046.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-047.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-048.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-049.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-050.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-051.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-056.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-057.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-058.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-059.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-060.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-061-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-061.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-062.xht37
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-067.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-068.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-069-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-069.xht39
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-070.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-071.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-072-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-072.xht39
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-073.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-078.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-079.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-080-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-080.xht39
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-081.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-082.xht38
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-083-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-083.xht39
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-084.xht39
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-089-ref.xht32
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-089.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-090.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-091-ref.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-091.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-092.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-093.xht40
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-094.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-095.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-100.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-101.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-102.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-103.xht42
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-001.xht56
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-002.xht56
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-003.xht56
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-004.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-005.xht55
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-006.xht55
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-007.xht44
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-008.xht32
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-009.xht41
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-010.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-012.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-013.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-014.xht51
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-015.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-001.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-002.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-003.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-004.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-001.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-002.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-003.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-004.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-005.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-006.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-007.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-012.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-013.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-014.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-015.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-016.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-017.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-018.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-023.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-024.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-025.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-026.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-027.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-028.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-029.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-034.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-035.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-036.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-037.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-038.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-039.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-040.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-045.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-046.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-047.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-048.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-049.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-050.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-051.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-056.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-057.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-058.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-059.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-060.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-061.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-062.xht30
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-067.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-068.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-069.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-070.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-071.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-072.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-073.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-078.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-079.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-080.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-081.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-082.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-083.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-084.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-089.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-090.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-091-ref.xht28
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-091.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-092.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-093.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-094.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-095.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-100.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-101.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-102.xht29
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-103-ref.xht28
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-103.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-001.xht55
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-002.xht55
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-003.xht55
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-004.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-005.xht54
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-006.xht54
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-007.xht44
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-008.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-009.xht36
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-010.xht34
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-012.xht35
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-013.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-014.xht50
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-015.xht49
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/100x100-lime.pngbin0 -> 649 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/100x100-red.pngbin0 -> 510 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/blue15x15.pngbin0 -> 185 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/diamond.pngbin0 -> 188 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/green15x15.pngbin0 -> 170 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-border-padding-002.pngbin0 -> 965 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-013.pngbin0 -> 1322 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-020.pngbin0 -> 1305 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-2em-space.pngbin0 -> 1331 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-4em-space.pngbin0 -> 1370 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/pattern-grg-rgr-grg.pngbin0 -> 222 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/pattern-rgr-grg-rgr.pngbin0 -> 223 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/ring.pngbin0 -> 715 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-001.pngbin0 -> 1419 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-002.pngbin0 -> 1377 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-003.pngbin0 -> 1457 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-004.pngbin0 -> 1766 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-blue.pngbin0 -> 84 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-green.pngbin0 -> 84 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-orange.pngbin0 -> 84 bytes
-rw-r--r--testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-white.pngbin0 -> 85 bytes
874 files changed, 32521 insertions, 0 deletions
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-001-ref.xht
new file mode 100644
index 0000000000..174123a6b1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-001-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ table, td {border: green solid 10px;}
+
+ table {border-spacing: 96px 96px;}
+
+ td {padding: 0.5in 1.5in ;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <table>
+ <tr><td></td></tr>
+ </table>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-001.xht
new file mode 100644
index 0000000000..85264b1a98
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-001.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin set using a single value</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property set using a single value properly assigns the same value to all sides." />
+ <style type="text/css">
+ #wrapper
+ {
+ position: relative;
+ }
+ #div1, #div2
+ {
+ border: 10px solid green;
+ }
+ #div1, #reference
+ {
+ left: 0;
+ position: absolute;
+ top: 0;
+ }
+ #div2
+ {
+ margin: 2.54cm;
+ height: 1in;
+ width: 3in;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 308px;
+ width: 500px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-002-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-002-ref.xht
new file mode 100644
index 0000000000..b731d00d0f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-002-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ table, td {border: green solid 10px;}
+
+ table {border-spacing: 48px 96px;}
+
+ td {padding: 48px 144px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <table>
+ <tr><td></td></tr>
+ </table>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-002.xht
new file mode 100644
index 0000000000..a2de2f9ec3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-002.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin set to using two values</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-002-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property set using two values properly assigns the first value to the top and bottom margins and the second value to the left and right margins." />
+ <style type="text/css">
+ #wrapper
+ {
+ position: relative;
+ }
+ #div1, #div2
+ {
+ border: 10px solid green;
+ }
+ #div1, #reference
+ {
+ left: 0;
+ position: absolute;
+ top: 0;
+ }
+ #div2
+ {
+ margin: 2.54cm 0.5in;
+ height: 1in;
+ width: 3in;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 308px;
+ width: 404px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-003-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-003-ref.xht
new file mode 100644
index 0000000000..803d424ed6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-003-ref.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border: green solid 10px;}
+
+ div#inline-block
+ {
+ padding: 96px 48px 192px;
+ width: 308px;
+ }
+
+ div#block {padding: 48px 144px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div id="inline-block">
+ <div id="block"></div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-003.xht
new file mode 100644
index 0000000000..cc8362fdba
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-003.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin set to using three values</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-003-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property set using three values properly assigns the first value to the top margin, the second value to the left and right margins, and the third value to the bottom margin." />
+ <style type="text/css">
+ #wrapper
+ {
+ position: relative;
+ }
+ #div1, #div2
+ {
+ border: 10px solid green;
+ }
+ #div1, #reference
+ {
+ left: 0;
+ position: absolute;
+ top: 0;
+ }
+ #div2
+ {
+ height: 1in;
+ margin: 2.54cm 0.5in 144pt;
+ width: 3in;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 404px;
+ width: 404px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-004-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-004-ref.xht
new file mode 100644
index 0000000000..9c93b425a3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-004-ref.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border: green solid 10px;}
+
+ div#inline-block
+ {
+ padding: 96px 24px 192px 48px;
+ width: 308px;
+ }
+
+ div#block {padding: 48px 144px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div id="inline-block">
+ <div id="block"></div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-004.xht
new file mode 100644
index 0000000000..6fb987ffb8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-004.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin set to using four values</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property set using three values properly assigns the first value to the top margin, the second value to the left margin, the third value to the bottom margin, and the fourth value to the right margin." />
+ <style type="text/css">
+ #wrapper
+ {
+ position: relative;
+ }
+ #div1, #div2
+ {
+ border: 10px solid green;
+ }
+ #div1, #reference
+ {
+ left: 0;
+ position: absolute;
+ top: 0;
+ }
+ #div2
+ {
+ margin: 2.54cm 0.25in 144pt 12.7mm;
+ height: 1in;
+ width: 3in;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 404px;
+ width: 380px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-005-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-005-ref.xht
new file mode 100644
index 0000000000..c6666afd2a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-005-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border: green solid 20px;
+ height: 96px;
+ width: 288px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-005.xht
new file mode 100644
index 0000000000..14d620b204
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-005.xht
@@ -0,0 +1,58 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin with a value of 'auto'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-005-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property with a value of 'auto' correctly sizes the margin. In normal flow, 'margin-top: auto' and 'margin-bottom: auto' for block-level, non-replaced elements are resolved as 0. In normal flow, 'margin-left: auto' and 'margin-right: auto' for block-level, non-replaced elements are resolved according to the constraint equation for the width of containing block: 'margin-left' + 'border-left-width' + 'padding-left' + 'width' + 'padding-right' + 'border-right-width' + 'margin-right' = width of containing block" />
+ <style type="text/css">
+ #wrapper
+ {
+ position: relative;
+ }
+ #div1, #div2
+ {
+ border: 10px solid green;
+ }
+ #div1, #reference
+ {
+ left: 0;
+ position: absolute;
+ top: 0;
+ }
+
+ /*
+ In this test, #div1, which is absolutely positioned, is
+ #div2's containing block. In which case, the width of #div1 is
+ shrink-to-fit to the width of #div2 plus its borders.
+ http://www.w3.org/TR/CSS21/visudet.html#abs-non-replaced-width
+ */
+
+ #div2
+ {
+ height: 1in;
+ margin: auto;
+ width: 3in;
+ }
+ #reference
+ {
+ border: 20px solid red;
+ height: 96px;
+ width: 288px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-006-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-006-ref.xht
new file mode 100644
index 0000000000..33199bad8c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-006-ref.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ table, td {border: green solid 10px;}
+
+ table
+ {
+ border-spacing: 96px;
+ left: 96px;
+ position: relative;
+ top: 96px;
+ }
+
+ td {padding: 48px 144px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <table>
+ <tr><td></td></tr>
+ </table>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-006.xht
new file mode 100644
index 0000000000..2df49b6c17
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-006.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin set to 'inherit', inheriting only one value</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-006-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property set to 'inherit', inherits one value from the parent element." />
+ <style type="text/css">
+ #wrapper
+ {
+ position: relative;
+ }
+ #div1, #div2
+ {
+ border: 10px solid green;
+ }
+ #div1, #reference
+ {
+ position: absolute;
+ }
+ #div1
+ {
+ left: 0;
+ margin: 2.54cm;
+ top: 0;
+ }
+ #div2
+ {
+ height: 1in;
+ margin: inherit;
+ width: 3in;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 308px;
+ left: 1in;
+ top: 1in;
+ width: 500px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-007-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-007-ref.xht
new file mode 100644
index 0000000000..2b26aacb9d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-007-ref.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ table, td {border: green solid 10px;}
+
+ table
+ {
+ border-spacing: 24px 96px;
+ left: 24px;
+ position: relative;
+ top: 96px;
+ }
+
+ td {padding: 48px 144px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <table>
+ <tr><td></td></tr>
+ </table>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-007.xht
new file mode 100644
index 0000000000..ec21059645
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-007.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin set to 'inherit', inheriting two values</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-007-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property set to 'inherit', inherits two values from the parent element." />
+ <style type="text/css">
+ #wrapper
+ {
+ position: relative;
+ }
+ #div1, #div2
+ {
+ border: 10px solid green;
+ }
+ #div1, #reference
+ {
+ position: absolute;
+ }
+ #div1
+ {
+ left: 0;
+ margin: 2.54cm 0.25in;
+ top: 0;
+ }
+ #div2
+ {
+ height: 1in;
+ margin: inherit;
+ width: 3in;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 308px;
+ left: 0.25in;
+ top: 1in;
+ width: 356px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-008-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-008-ref.xht
new file mode 100644
index 0000000000..483003574a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-008-ref.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border: green solid 10px;}
+
+ div#inline-block
+ {
+ left: 24px;
+ padding: 96px 24px 192px;
+ position: relative;
+ top: 96px;
+ width: 308px;
+ }
+
+ div#block {padding: 48px 144px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div id="inline-block">
+ <div id="block"></div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-008.xht
new file mode 100644
index 0000000000..468884d2c5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-008.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin set to 'inherit', inheriting three values</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-008-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property set to 'inherit', inherits three values from the parent element." />
+ <style type="text/css">
+ #wrapper
+ {
+ position: relative;
+ }
+ #div1, #div2
+ {
+ border: 10px solid green;
+ }
+ #div1, #reference
+ {
+ position: absolute;
+ }
+ #div1
+ {
+ left: 0;
+ margin: 2.54cm 0.25in 144pt;
+ top: 0;
+ }
+ #div2
+ {
+ height: 1in;
+ margin: inherit;
+ width: 3in;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 404px;
+ left: 0.25in;
+ top: 1in;
+ width: 356px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-009-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-009-ref.xht
new file mode 100644
index 0000000000..4cbe99b7ea
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-009-ref.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border: green solid 10px;}
+
+ div#inline-block
+ {
+ left: 48px;
+ padding: 96px 24px 192px 48px;
+ position: relative;
+ top: 96px;
+ width: 308px;
+ }
+
+ div#block {padding: 48px 144px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div id="inline-block">
+ <div id="block"></div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-009.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-009.xht
new file mode 100644
index 0000000000..afb4bb9880
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-009.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin set to 'inherit', inheriting four values</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property set to 'inherit', inherits four values from the parent element." />
+ <style type="text/css">
+ #wrapper
+ {
+ position: relative;
+ }
+ #div1, #div2
+ {
+ border: 10px solid green;
+ }
+ #div1, #reference
+ {
+ position: absolute;
+ }
+ #div1
+ {
+ left: 0;
+ margin: 2.54cm 0.25in 144pt 12.7mm;
+ top: 0;
+ }
+ #div2
+ {
+ height: 1in;
+ margin: inherit;
+ width: 3in;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 404px;
+ left: 0.5in;
+ top: 1in;
+ width: 380px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-001-ref.xht
new file mode 100644
index 0000000000..10c0ce890e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-001-ref.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div#parent
+ {
+ border: blue solid 10px;
+ float: left;
+ }
+
+ div#child
+ {
+ border: orange solid 10px;
+ height: 200px;
+ width: 200px;
+ }
+
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+
+ <div id="parent">
+ <div id="child"></div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-001.xht
new file mode 100644
index 0000000000..468ca8eb2b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-001.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin applied to element with display table-row-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property does not apply to elements with a display of table-row-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border: 10px solid blue;
+ position: absolute;
+ }
+ #test
+ {
+ display: table-row-group;
+ margin: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-002.xht
new file mode 100644
index 0000000000..619381c5c5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-002.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin applied to element with display table-header-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property does not apply to elements with a display of table-header-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border: 10px solid blue;
+ position: absolute;
+ }
+ #test
+ {
+ display: table-header-group;
+ margin: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-003.xht
new file mode 100644
index 0000000000..02f8b373fb
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-003.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin applied to element with display table-footer-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property does not apply to elements with a display of table-footer-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border: 10px solid blue;
+ position: absolute;
+ }
+ #test
+ {
+ display: table-footer-group;
+ margin: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-004.xht
new file mode 100644
index 0000000000..9a90f4f664
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-004.xht
@@ -0,0 +1,46 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin applied to element with display table-row</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property does not apply to elements with a display of table-row." />
+ <style type="text/css">
+ #wrapper
+ {
+ border: 10px solid blue;
+ position: absolute;
+ }
+ #test
+ {
+ display: table-row;
+ margin: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #cell
+ {
+ border: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-005.xht
new file mode 100644
index 0000000000..3add8b9f0e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-005.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin applied to element with display table-column-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property does not apply to elements with a display of table-column-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border: 10px solid blue;
+ position: absolute;
+ }
+ #test
+ {
+ display: table-column-group;
+ margin: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-006.xht
new file mode 100644
index 0000000000..a499cf2446
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-006.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin applied to element with display table-column</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property does not apply to elements with a display of table-column." />
+ <style type="text/css">
+ #wrapper
+ {
+ border: 10px solid blue;
+ position: absolute;
+ }
+ #test
+ {
+ display: table-column;
+ margin: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-007.xht
new file mode 100644
index 0000000000..272a72a441
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-007.xht
@@ -0,0 +1,46 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin applied to element with display table-cell</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin' property does not apply to elements with a display of table-cell." />
+ <style type="text/css">
+ #wrapper
+ {
+ border: 10px solid blue;
+ position: absolute;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ margin: 50px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-008.xht
new file mode 100644
index 0000000000..c414ade390
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-008.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin applied to element with display inline</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-31 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <meta name="assert" content="The 'Margin' property applies to elements with a display of inline. Only horizontal margins apply to inline non-repleaced elements; vertical margins do not and will not apply to inline non-repleaced elements." />
+ <style type="text/css">
+ div
+ {
+ display: inline;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ border-right: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ border-right: 5px solid orange;
+ margin: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="div1">
+ <div>Filler Text</div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-009-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-009-ref.xht
new file mode 100644
index 0000000000..287a58e369
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-009-ref.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div#parent
+ {
+ border: blue solid 10px;
+ float: left;
+ padding: 50px;
+ }
+
+ div#child
+ {
+ border: orange solid 10px;
+ height: 200px;
+ width: 200px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is space between the blue and orange lines on all four sides.</p>
+
+ <div id="parent">
+ <div id="child"></div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-009.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-009.xht
new file mode 100644
index 0000000000..7faa285e62
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-009.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin applied to element with display block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'Margin' property applies to elements with a display of block." />
+ <style type="text/css">
+ div
+ {
+ display: block;
+ }
+ #wrapper
+ {
+ border: 10px solid blue;
+ position: absolute;
+ }
+ #test
+ {
+ border: 10px solid orange;
+ height: 200px;
+ margin: 50px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines on all four sides.</p>
+ <div id="wrapper">
+ <div id="test"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-010.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-010.xht
new file mode 100644
index 0000000000..a00ed2badb
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-010.xht
@@ -0,0 +1,32 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin applied to element with display list-item</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <meta name="assert" content="The 'Margin' property applies to elements with a display of list-item." />
+ <style type="text/css">
+ #wrapper
+ {
+ border: 10px solid blue;
+ position: absolute;
+ }
+ #test
+ {
+ border: 10px solid orange;
+ display: list-item;
+ height: 200px;
+ width: 200px;
+ margin: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines and there is a marker bullet on the left-hand side of the orange box.</p>
+ <div id="wrapper">
+ <div id="test"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-012.xht
new file mode 100644
index 0000000000..9f5d1b445b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-012.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin applied to element with display inline-block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'Margin' property applies to elements with a display of inline-block." />
+ <style type="text/css">
+ #wrapper
+ {
+ border: 10px solid blue;
+ position: absolute;
+ }
+ #test
+ {
+ border: 10px solid orange;
+ display: inline-block;
+ height: 200px;
+ width: 200px;
+ margin: 50px;
+ vertical-align: bottom;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines on all four sides.</p>
+ <div id="wrapper">
+ <div id="test"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-013.xht
new file mode 100644
index 0000000000..2cb806fa9e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-013.xht
@@ -0,0 +1,47 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin applied to element with display table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'Margin' property applies to elements with a display of table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border: 10px solid blue;
+ position: absolute;
+ }
+ #table
+ {
+ border: 10px solid orange;
+ display: table;
+ table-layout: fixed;
+ margin: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines on all four sides.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-014.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-014.xht
new file mode 100644
index 0000000000..445ba6d9c5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-014.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin applied to element with display inline-table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'Margin' property applies to elements with a display of inline-table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border: 10px solid blue;
+ position: absolute;
+ }
+ #table
+ {
+ border: 10px solid orange;
+ display: inline-table;
+ table-layout: fixed;
+ margin: 50px;
+ vertical-align: top;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines on all four sides.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-015.xht
new file mode 100644
index 0000000000..b15ec1c1eb
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-applies-to-015.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin applied to element with display table-caption</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'Margin' property applies to elements with a display of table-caption." />
+ <style type="text/css">
+ #wrapper
+ {
+ border: 10px solid blue;
+ position: absolute;
+ }
+ #test
+ {
+ border: 10px solid orange;
+ display: table-caption;
+ height: 200px;
+ margin: 50px;
+ }
+ #table
+ {
+ display: table;
+ width: 320px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines on all four sides.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-auto-on-block-box-ref.html b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-auto-on-block-box-ref.html
new file mode 100644
index 0000000000..efc41cff10
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-auto-on-block-box-ref.html
@@ -0,0 +1,54 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Reftest Reference</title>
+<link rel="author" title="Oriol Brufau" href="mailto:obrufau@igalia.com">
+<link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+
+<pre style="font: 5px/1 Ahem">
+ XXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+ XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+</pre> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-auto-on-block-box.html b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-auto-on-block-box.html
new file mode 100644
index 0000000000..1afc98a913
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-auto-on-block-box.html
@@ -0,0 +1,78 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<title>CSS Test: Resolution of margin-left or margin-right set to auto on a non-replaced block box</title>
+<link rel="match" href="margin-auto-on-block-box-ref.html">
+<link rel="help" href="https://drafts.csswg.org/css2/#blockwidth">
+<link rel="author" title="Oriol Brufau" href="mailto:obrufau@igalia.com">
+<meta name="assert" content="
+ margin-left:auto shouldn't resolve to a negative amount (assuming direction:ltr).
+ margin-right:auto may resolve to a negative amount when there is over-constraintment.">
+
+<style>
+.wrapper {
+ width: 100px;
+ margin-left: 250px;
+}
+.test {
+ width: 50px;
+ height: 5px;
+ background: black;
+ margin: auto;
+}
+.test.big {
+ width: 200px;
+}
+</style>
+
+<div class="wrapper">
+ <div class="test"></div>
+ <div class="test big"></div>
+
+ <div class="test" style="margin-left: -125px"></div>
+ <div class="test" style="margin-left: -100px"></div>
+ <div class="test" style="margin-left: -75px"></div>
+ <div class="test" style="margin-left: -50px"></div>
+ <div class="test" style="margin-left: -25px"></div>
+ <div class="test" style="margin-left: 0"></div>
+ <div class="test" style="margin-left: 25px"></div>
+ <div class="test" style="margin-left: 50px"></div>
+ <div class="test" style="margin-left: 75px"></div>
+ <div class="test" style="margin-left: 100px"></div>
+ <div class="test" style="margin-left: 125px"></div>
+
+ <div class="test big" style="margin-left: -250px"></div>
+ <div class="test big" style="margin-left: -200px"></div>
+ <div class="test big" style="margin-left: -150px"></div>
+ <div class="test big" style="margin-left: -100px"></div>
+ <div class="test big" style="margin-left: -50px"></div>
+ <div class="test big" style="margin-left: 0"></div>
+ <div class="test big" style="margin-left: 50px"></div>
+ <div class="test big" style="margin-left: 100px"></div>
+ <div class="test big" style="margin-left: 150px"></div>
+ <div class="test big" style="margin-left: 200px"></div>
+ <div class="test big" style="margin-left: 250px"></div>
+
+ <div class="test" style="margin-right: -125px"></div>
+ <div class="test" style="margin-right: -100px"></div>
+ <div class="test" style="margin-right: -75px"></div>
+ <div class="test" style="margin-right: -50px"></div>
+ <div class="test" style="margin-right: -25px"></div>
+ <div class="test" style="margin-right: 0"></div>
+ <div class="test" style="margin-right: 25px"></div>
+ <div class="test" style="margin-right: 50px"></div>
+ <div class="test" style="margin-right: 75px"></div>
+ <div class="test" style="margin-right: 100px"></div>
+ <div class="test" style="margin-right: 125px"></div>
+
+ <div class="test big" style="margin-right: -250px"></div>
+ <div class="test big" style="margin-right: -200px"></div>
+ <div class="test big" style="margin-right: -150px"></div>
+ <div class="test big" style="margin-right: -100px"></div>
+ <div class="test big" style="margin-right: -50px"></div>
+ <div class="test big" style="margin-right: 0"></div>
+ <div class="test big" style="margin-right: 50px"></div>
+ <div class="test big" style="margin-right: 100px"></div>
+ <div class="test big" style="margin-right: 150px"></div>
+ <div class="test big" style="margin-right: 200px"></div>
+ <div class="test big" style="margin-right: 250px"></div>
+</div>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-backgrounds-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-backgrounds-001.xht
new file mode 100644
index 0000000000..5a2a4f3039
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-backgrounds-001.xht
@@ -0,0 +1,26 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin backgrounds and transparency</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#box-dimensions" />
+ <meta name="assert" content="Margins do not have a background, but show the content below them." />
+ <style type="text/css">
+ #div1
+ {
+ border: 1px blue solid;
+ }
+ div div
+ {
+ background: orange;
+ margin: 20px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a white background between the blue outer box and the orange box.</p>
+ <div id="div1">
+ <div>Filler Text</div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-backgrounds-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-backgrounds-002.xht
new file mode 100644
index 0000000000..75c0211ca4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-backgrounds-002.xht
@@ -0,0 +1,58 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Test: transparency of margin area and background-color</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#mpb-examples" title="8.2 Example of margins, padding, and borders" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/colors.html#background" title="14.2 The background" />
+ <link rel="match" href="../reference/ref-filled-green-100px-square.xht" />
+
+ <meta content="The margin area of an element is always transparent. The background-color of an element never paints its own margin area. The background-color of an element only paints its own border area (if any), its own padding area (if any) and its own content area (if any). Therefore the background-color of the content area (and of the padding area, if any, and of the border area, if any) of a parent element shines through the margin area of its child. In this test, div#parent is painted green and is 100px by 100px; its sole child has an 99px margin bottom and a 100px margin right margin which are transparent and through which we can see the background color of its parent." name="assert" />
+
+ <style type="text/css"><![CDATA[
+ p {margin: 1em 0em;}
+
+ div#parent
+ {
+ background-color: green;
+ height: 100px;
+ width: 100px;
+ }
+
+ div#child
+ {
+ background-color: red;
+ height: 1px;
+ /*
+ 'height: 1px' is set intentionally so that the
+ top margin (16px) and bottom margin (99px) of such child
+ box do not collapse through the element.
+ */
+ margin: 16px 100px 99px 0px;
+ /*
+ 'margin-top: 16px' correspond to the margin-bottom of the
+ <p>. The margin-top of the child box collapses with the
+ margin-top of div#parent and then the collapsed margin-top
+ of div#parent then collapses in its turn with the
+ margin-bottom of the <p>.
+ */
+ width: auto;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+
+ <div id="parent">
+ <div id="child"></div>
+ </div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-backgrounds-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-backgrounds-003.xht
new file mode 100644
index 0000000000..51d0a619e1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-backgrounds-003.xht
@@ -0,0 +1,47 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Test: transparency of margin area and background-color</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#mpb-examples" title="8.2 Example of margins, padding, and borders" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/colors.html#background" title="14.2 The background" />
+ <link rel="match" href="../reference/ref-filled-green-100px-square.xht" />
+
+ <meta content="The margin area of an element is always transparent. The background-color of an element never paints its own margin area. The background-color of an element only paints its own border area (if any), its own padding area (if any) and its own content area (if any). Therefore the background-color of the content area (and of the padding area, if any, and of the border area, if any) of a parent element shines through the margin area of its child. In this test, div#parent is painted green and is 100px wide by 98px tall; its sole child has 98px vertical margins and 100px horizontal margins which are transparent and through which we can see the background color of its parent." name="assert" />
+
+ <style type="text/css"><![CDATA[
+ div#parent
+ {
+ background-color: green;
+ border-top: green solid 2px;
+ /*
+ This border-top's sole purpose is to prevent margin
+ collapsing between itself and the p's margin-bottom
+ */
+ height: 98px;
+ width: 100px;
+ }
+
+ div#child
+ {
+ background-color: red;
+ margin: 49px 50px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+
+ <div id="parent">
+ <div id="child"></div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-001-ref.xht
new file mode 100644
index 0000000000..0578570aae
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-001-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: black;
+ height: 80px;
+ margin: 32px;
+ width: 112px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-001.xht
new file mode 100644
index 0000000000..818ed0b3c1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-001.xht
@@ -0,0 +1,47 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin, border, padding all display outside the content area</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#box-dimensions" />
+ <link rel="match" href="margin-border-padding-001-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="Margin, border, padding render outside the content area." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 1em/1 Ahem;
+ margin: 1em;
+ left: 0;
+ padding: 1em;
+ position: absolute;
+ top: 0;
+ }
+ #div1
+ {
+ position: relative;
+ }
+ #div2
+ {
+ background: red;
+ border: 1em solid red;
+ color: red;
+ }
+ #div3
+ {
+ background: black;
+ border: 1em solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2">XXX</div>
+ <div id="div3">XXX</div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-002.xht
new file mode 100644
index 0000000000..381d1bdb71
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-002.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin, border, padding all display outside the image area</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#box-dimensions" />
+ <link rel="match" href="margin-border-padding-001-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="Margin, border, padding render outside the image area." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 1em/1 Ahem;
+ margin: 1em;
+ left: 0;
+ padding: 1em;
+ position: absolute;
+ top: 0;
+ }
+ #div1
+ {
+ position: relative;
+ }
+ #div2
+ {
+ background: red;
+ border: 1em solid red;
+ color: red;
+ }
+ #div3
+ {
+ background: black;
+ border: 1em solid black;
+ }
+ img
+ {
+ vertical-align: top;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2">XXX</div>
+ <div id="div3"><img alt="1x3 'em' unit box" src="support/margin-border-padding-002.png" /></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-003.xht
new file mode 100644
index 0000000000..01e6dd7b0b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-border-padding-003.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin, border, padding all display outside the object area</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#box-dimensions" />
+ <link rel="match" href="margin-border-padding-001-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="Margin, border, padding render outside the object area." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 1em/1 Ahem;
+ margin: 1em;
+ left: 0;
+ padding: 1em;
+ position: absolute;
+ top: 0;
+ }
+ #div1
+ {
+ position: relative;
+ }
+ #div2
+ {
+ background: red;
+ border: 1em solid red;
+ color: red;
+ }
+ #div3
+ {
+ background: black;
+ border: 1em solid black;
+ }
+ object
+ {
+ vertical-align: top;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2">XXX</div>
+ <div id="div3"><object type="image/png" data="support/margin-border-padding-002.png"></object></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-004.xht
new file mode 100644
index 0000000000..869cf9385e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-004.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using pixels with a negative zero value, -0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a negative zero length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: -0px;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-005.xht
new file mode 100644
index 0000000000..88ab485357
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-005.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using pixels with a zero value, 0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a zero length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: 0px;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-006.xht
new file mode 100644
index 0000000000..db983feb90
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-006.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using pixels with a positive zero value, +0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a positive zero length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: +0px;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-007-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-007-ref.xht
new file mode 100644
index 0000000000..887d437719
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-007-ref.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: black;
+ height: 5px;
+ }
+
+ div + div
+ {
+ position: relative;
+ top: 96px;
+ }
+
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-007.xht
new file mode 100644
index 0000000000..859e29f57e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-007.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using pixels with a nominal value, 96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-007-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in pixels." />
+ <style type="text/css">
+ #wrapper
+ {
+ height: 101px;
+ border-bottom: 5px solid red;
+ }
+ #div1
+ {
+ border-bottom: 5px solid black;
+ margin-bottom: 96px;
+ }
+ #div2
+ {
+ border-top: 5px solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-008.xht
new file mode 100644
index 0000000000..ce0ae2f4c9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-008.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using pixels with a nominal value with a plus sign, +96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-007-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in pixels with a plus sign." />
+ <style type="text/css">
+ #wrapper
+ {
+ height: 101px;
+ border-bottom: 5px solid red;
+ }
+ #div1
+ {
+ border-bottom: 5px solid black;
+ margin-bottom: +96px;
+ }
+ #div2
+ {
+ border-top: 5px solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-016.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-016.xht
new file mode 100644
index 0000000000..202d907685
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-016.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using points with a negative zero value, -0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a negative zero length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: -0pt;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-017.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-017.xht
new file mode 100644
index 0000000000..970313dd39
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-017.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using points with a zero value, 0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a zero length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: 0pt;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-018.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-018.xht
new file mode 100644
index 0000000000..fe9c09c5b4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-018.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using points with a positive zero value, +0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a positive zero length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: +0pt;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-019-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-019-ref.xht
new file mode 100644
index 0000000000..447411ae34
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-019-ref.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: black;
+ height: 8px;
+ }
+
+ div + div
+ {
+ position: relative;
+ top: 96px;
+ }
+
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-019.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-019.xht
new file mode 100644
index 0000000000..a7cb15d064
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-019.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using points with a nominal value, 72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-019-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in points." />
+ <style type="text/css">
+ #wrapper
+ {
+ height: 78pt;
+ border-bottom: 6pt solid red;
+ }
+ #div1
+ {
+ border-bottom: 6pt solid black;
+ margin-bottom: 72pt;
+ }
+ #div2
+ {
+ border-top: 6pt solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-020.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-020.xht
new file mode 100644
index 0000000000..99800e4ca1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-020.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using points with a nominal value with a plus sign, +72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-019-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in points with a plus sign." />
+ <style type="text/css">
+ #wrapper
+ {
+ height: 78pt;
+ border-bottom: 6pt solid red;
+ }
+ #div1
+ {
+ border-bottom: 6pt solid black;
+ margin-bottom: +72pt;
+ }
+ #div2
+ {
+ border-top: 6pt solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-028.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-028.xht
new file mode 100644
index 0000000000..7925fcb2fd
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-028.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using picas with a negative zero value, -0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a negative zero length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: -0pc;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-029.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-029.xht
new file mode 100644
index 0000000000..5f9e225cb1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-029.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using picas with a zero value, 0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a zero length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: 0pc;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-030.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-030.xht
new file mode 100644
index 0000000000..3b64f29928
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-030.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using picas with a positive zero value, +0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a positive zero length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: +0pc;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-031-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-031-ref.xht
new file mode 100644
index 0000000000..394b505ad1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-031-ref.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: black;
+ height: 16px;
+ }
+
+ div + div
+ {
+ position: relative;
+ top: 96px;
+ }
+
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-031.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-031.xht
new file mode 100644
index 0000000000..4cf74fc375
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-031.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using picas with a nominal value, 6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-031-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in picas." />
+ <style type="text/css">
+ #wrapper
+ {
+ height: 7pc;
+ border-bottom: 1pc solid red;
+ }
+ #div1
+ {
+ border-bottom: 1pc solid black;
+ margin-bottom: 6pc;
+ }
+ #div2
+ {
+ border-top: 1pc solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-032.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-032.xht
new file mode 100644
index 0000000000..ade5b3fdf2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-032.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using picas with a nominal value with a plus sign, +6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-031-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in picas with a plus sign." />
+ <style type="text/css">
+ #wrapper
+ {
+ height: 7pc;
+ border-bottom: 1pc solid red;
+ }
+ #div1
+ {
+ border-bottom: 1pc solid black;
+ margin-bottom: +6pc;
+ }
+ #div2
+ {
+ border-top: 1pc solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-040.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-040.xht
new file mode 100644
index 0000000000..e7f0857988
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-040.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using centimeters with a negative zero value, -0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a negative zero length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: -0cm;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-041.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-041.xht
new file mode 100644
index 0000000000..168a526cba
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-041.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using centimeters with a zero value, 0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a zero length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: 0cm;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-042.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-042.xht
new file mode 100644
index 0000000000..6d5cda8e57
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-042.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using centimeters with a positive zero value, +0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a positive zero length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: +0cm;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-043-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-043-ref.xht
new file mode 100644
index 0000000000..9e0a99d566
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-043-ref.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: black;
+ height: 96px;
+ }
+
+ div + div
+ {
+ position: relative;
+ top: 96px;
+ }
+
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-043.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-043.xht
new file mode 100644
index 0000000000..0e52b614ef
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-043.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using centimeters with a nominal value, 2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in centimeters." />
+ <style type="text/css">
+ #wrapper
+ {
+ height: 5.08cm;
+ border-bottom: 2.54cm solid red;
+ }
+ #div1
+ {
+ border-bottom: 2.54cm solid black;
+ margin-bottom: 2.54cm;
+ }
+ #div2
+ {
+ border-top: 2.54cm solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-044.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-044.xht
new file mode 100644
index 0000000000..0c399b9af0
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-044.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using centimeters with a nominal value with a plus sign, +2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in centimeters with a plus sign." />
+ <style type="text/css">
+ #wrapper
+ {
+ height: 5.08cm;
+ border-bottom: 2.54cm solid red;
+ }
+ #div1
+ {
+ border-bottom: 2.54cm solid black;
+ margin-bottom: +2.54cm;
+ }
+ #div2
+ {
+ border-top: 2.54cm solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-052.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-052.xht
new file mode 100644
index 0000000000..5ff964ba1d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-052.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using millimeters with a negative zero value, -0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a negative zero length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: -0mm;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-053.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-053.xht
new file mode 100644
index 0000000000..db564e5b87
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-053.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using millimeters with a zero value, 0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a zero length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: 0mm;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-054.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-054.xht
new file mode 100644
index 0000000000..0bc5972c62
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-054.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using millimeters with a positive zero value, +0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a positive zero length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: +0mm;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-055.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-055.xht
new file mode 100644
index 0000000000..e006081b2e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-055.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using millimeters with a nominal value, 25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in millimeters." />
+ <style type="text/css">
+ #wrapper
+ {
+ height: 50.8mm;
+ border-bottom: 25.4mm solid red;
+ }
+ #div1
+ {
+ border-bottom: 25.4mm solid black;
+ margin-bottom: 25.4mm;
+ }
+ #div2
+ {
+ border-top: 25.4mm solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-056.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-056.xht
new file mode 100644
index 0000000000..705d9c51ae
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-056.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using millimeters with a nominal value with a plus sign, +25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in millimeters with a plus sign." />
+ <style type="text/css">
+ #wrapper
+ {
+ height: 50.8mm;
+ border-bottom: 25.4mm solid red;
+ }
+ #div1
+ {
+ border-bottom: 25.4mm solid black;
+ margin-bottom: +25.4mm;
+ }
+ #div2
+ {
+ border-top: 25.4mm solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-064.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-064.xht
new file mode 100644
index 0000000000..cafcedb277
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-064.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using inches with a negative zero value, -0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a negative zero length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: -0in;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-065.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-065.xht
new file mode 100644
index 0000000000..fb3396027a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-065.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using inches with a zero value, 0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a zero length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: 0in;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-066.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-066.xht
new file mode 100644
index 0000000000..a558c95653
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-066.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using inches with a positive zero value, +0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a positive zero length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: +0in;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-067-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-067-ref.xht
new file mode 100644
index 0000000000..28ea838c76
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-067-ref.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: black;
+ height: 24px;
+ }
+
+ div + div
+ {
+ position: relative;
+ top: 96px;
+ }
+
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-067.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-067.xht
new file mode 100644
index 0000000000..691a8dc199
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-067.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using inches with a nominal value, 1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-067-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in inches." />
+ <style type="text/css">
+ #wrapper
+ {
+ height: 1.25in;
+ border-bottom: 0.25in solid red;
+ }
+ #div1
+ {
+ border-bottom: 0.25in solid black;
+ margin-bottom: 1in;
+ }
+ #div2
+ {
+ border-top: 0.25in solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-068.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-068.xht
new file mode 100644
index 0000000000..de7fbc0cb3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-068.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using inches with a nominal value with a plus sign, +1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-067-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in inches with a plus sign." />
+ <style type="text/css">
+ #wrapper
+ {
+ height: 1.25in;
+ border-bottom: 0.25in solid red;
+ }
+ #div1
+ {
+ border-bottom: 0.25in solid black;
+ margin-bottom: +1in;
+ }
+ #div2
+ {
+ border-top: 0.25in solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-076.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-076.xht
new file mode 100644
index 0000000000..7ac44accbf
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-076.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using 'em' units with a negative zero value, -0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a negative zero length value in 'em' units." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: -0em;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-077.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-077.xht
new file mode 100644
index 0000000000..530ca94390
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-077.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using 'em' units with a zero value, 0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a zero length value in 'em' units." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: 0em;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-078.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-078.xht
new file mode 100644
index 0000000000..8dccb1986f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-078.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using 'em' units with a positive zero value, +0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a positive zero length value in 'em' units." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: +0em;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-079-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-079-ref.xht
new file mode 100644
index 0000000000..8007248b72
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-079-ref.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: black;
+ height: 20px;
+ }
+
+ div + div
+ {
+ position: relative;
+ top: 120px;
+ }
+
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-079.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-079.xht
new file mode 100644
index 0000000000..7f759ced5d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-079.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using 'em' units with a nominal value, 6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #wrapper
+ {
+ height: 7em;
+ border-bottom: 1em solid red;
+ }
+ #div1
+ {
+ border-bottom: 1em solid black;
+ margin-bottom: 6em;
+ }
+ #div2
+ {
+ border-top: 1em solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-080.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-080.xht
new file mode 100644
index 0000000000..b68504440d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-080.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using 'em' units with a nominal value with a plus sign, +6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in 'em' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #wrapper
+ {
+ height: 7em;
+ border-bottom: 1em solid red;
+ }
+ #div1
+ {
+ border-bottom: 1em solid black;
+ margin-bottom: +6em;
+ }
+ #div2
+ {
+ border-top: 1em solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-088.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-088.xht
new file mode 100644
index 0000000000..7940ddd068
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-088.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using 'ex' units with a negative zero value, -0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a negative zero length value in 'ex' units." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: -0ex;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-089.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-089.xht
new file mode 100644
index 0000000000..1436fee7fb
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-089.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using 'ex' units with a zero value, 0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a zero length value in 'ex' units." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: 0ex;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-090.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-090.xht
new file mode 100644
index 0000000000..93001192ea
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-090.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using 'ex' units with a positive zero value, +0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a positive zero length value in 'ex' units." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: +0ex;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-091-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-091-ref.xht
new file mode 100644
index 0000000000..dba27ae766
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-091-ref.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: black;
+ height: 16px;
+ }
+
+ div + div
+ {
+ position: relative;
+ top: 120px;
+ }
+
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-091.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-091.xht
new file mode 100644
index 0000000000..07e54b816c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-091.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using 'ex' units with a nominal value, 7.5ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-091-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #wrapper
+ {
+ height: 8.5ex;
+ border-bottom: 1ex solid red;
+ }
+ #div1
+ {
+ border-bottom: 1ex solid black;
+ margin-bottom: 7.5ex;
+ }
+ #div2
+ {
+ border-top: 1ex solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-092.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-092.xht
new file mode 100644
index 0000000000..ba61f43120
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-092.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using 'ex' units with a nominal value with a plus sign, +7.5ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-091-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in 'ex' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #wrapper
+ {
+ height: 8.5ex;
+ border-bottom: 1ex solid red;
+ }
+ #div1
+ {
+ border-bottom: 1ex solid black;
+ margin-bottom: +7.5ex;
+ }
+ #div2
+ {
+ border-top: 1ex solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-100-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-100-ref.xht
new file mode 100644
index 0000000000..609eb76ee2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-100-ref.xht
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: blue;
+ height: 5px;
+ width: 96px;
+ }
+
+ div + div {background-color: orange;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-100.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-100.xht
new file mode 100644
index 0000000000..446a83d881
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-100.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using percentages with a negative zero value, -0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-100-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a negative zero length value in percentages." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: -0%;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-101.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-101.xht
new file mode 100644
index 0000000000..976c01a7c4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-101.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using percentages with a zero value, 0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-100-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a zero length value in percentages." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: 0%;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-102.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-102.xht
new file mode 100644
index 0000000000..ce40ab52fa
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-102.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using percentages with a positive zero value, +0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-100-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a positive zero length value in percentages." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: +0%;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-103-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-103-ref.xht
new file mode 100644
index 0000000000..3b1902e698
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-103-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-top: black solid 3px;
+ bottom: 1em;
+ position: relative;
+ width: 192px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-103.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-103.xht
new file mode 100644
index 0000000000..89e05ff445
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-103.xht
@@ -0,0 +1,43 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using percentages with a nominal value, 50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-103-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in percentages." />
+ <style type="text/css">
+ div
+ {
+ position: relative;
+ width: 2in;
+ }
+ #div1
+ {
+ border-bottom: 3px solid red;
+ position: absolute;
+ width: 100%;
+ }
+ #div2
+ {
+ margin-bottom: 50%;
+ }
+ #div3
+ {
+ border-bottom: 3px solid black;
+ margin-top: -1in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ <div id="div3"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-104.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-104.xht
new file mode 100644
index 0000000000..30826dc07e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-104.xht
@@ -0,0 +1,43 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom using percentages with a nominal value with a plus sign, +50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-103-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a nominal length value in percentages with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ position: relative;
+ width: 2in;
+ }
+ #div1
+ {
+ border-bottom: 3px solid red;
+ position: absolute;
+ width: 100%;
+ }
+ #div2
+ {
+ margin-bottom: +50%;
+ }
+ #div3
+ {
+ border-bottom: 3px solid black;
+ margin-top: -1in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ <div id="div3"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-109.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-109.xht
new file mode 100644
index 0000000000..65f181dd09
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-109.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom sets a negative zero value with no units, -0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a negative zero length value with no units." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: -0;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-110.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-110.xht
new file mode 100644
index 0000000000..9fc5d1fb85
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-110.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom sets a zero value with no units, 0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a zero length value with no units." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: 0;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-111.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-111.xht
new file mode 100644
index 0000000000..95ca66019a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-111.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom sets a positive zero value with no units, +0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a positive zero length value with no units." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: +0;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-112.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-112.xht
new file mode 100644
index 0000000000..97b116457b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-112.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom with a value of 'auto'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-13 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a value of 'auto'." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ margin-bottom: auto;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-113.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-113.xht
new file mode 100644
index 0000000000..40a017e69b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-113.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom with a value of 'inherit'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-067-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property sets a value of 'inherit'." />
+ <style type="text/css">
+
+ #wrapper
+ {
+ border-bottom: 0.25in solid red;
+ height: 1.25in;
+ margin-bottom: 1in;
+ }
+ #div1
+ {
+ border-bottom: 0.25in solid black;
+ margin-bottom: inherit;
+ }
+ #div2
+ {
+ border-top: 0.25in solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-001-ref.xht
new file mode 100644
index 0000000000..4b52c33542
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-001-ref.xht
@@ -0,0 +1,39 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: orange;
+ height: 10px;
+ margin-top: 216px;
+ width: 200px;
+ }
+
+ div + div
+ {
+ background-color: blue;
+ margin-top: 0px;
+ width: auto;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-001.xht
new file mode 100644
index 0000000000..c476461d1c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-001.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom applied to element with display table-row-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property does not apply to elements with a display of table-row-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #test
+ {
+ display: table-row-group;
+ margin-bottom: 50px;
+ }
+ #table
+ {
+ display: table;
+ table-layout: fixed;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-bottom: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-002.xht
new file mode 100644
index 0000000000..4532761fb3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-002.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom applied to element with display table-header-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property does not apply to elements with a display of table-header-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #test
+ {
+ display: table-header-group;
+ margin-bottom: 50px;
+ }
+ #table
+ {
+ display: table;
+ table-layout: fixed;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-bottom: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-003.xht
new file mode 100644
index 0000000000..5b220a0b25
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-003.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom applied to element with display table-footer-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property does not apply to elements with a display of table-footer-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #test
+ {
+ display: table-footer-group;
+ margin-bottom: 50px;
+ }
+ #table
+ {
+ display: table;
+ table-layout: fixed;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-bottom: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-004.xht
new file mode 100644
index 0000000000..c7388eadfe
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-004.xht
@@ -0,0 +1,46 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom applied to element with display table-row</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property does not apply to elements with a display of table-row." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #table
+ {
+ display: table;
+ table-layout: fixed;
+ }
+ #row
+ {
+ display: table-row;
+ margin-bottom: 50px;
+ }
+ #cell
+ {
+ border-bottom: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-005.xht
new file mode 100644
index 0000000000..c808c1c452
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-005.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom applied to element with display table-column-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property does not apply to elements with a display of table-column-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #test
+ {
+ display: table-column-group;
+ margin-bottom: 50px;
+ }
+ #table
+ {
+ display: table;
+ table-layout: fixed;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-bottom: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-006.xht
new file mode 100644
index 0000000000..2408f2c085
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-006.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom applied to element with display table-column</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property does not apply to elements with a display of table-column." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #test
+ {
+ display: table-column;
+ margin-bottom: 50px;
+ }
+ #table
+ {
+ display: table;
+ table-layout: fixed;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-bottom: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-007.xht
new file mode 100644
index 0000000000..cab02e6b09
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-007.xht
@@ -0,0 +1,46 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom applied to element with 'display' 'table-cell'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property does not apply to elements with a 'display' of 'table-cell'." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #table
+ {
+ display: table;
+ table-layout: fixed;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-bottom: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ margin-bottom: 50px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-008-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-008-ref.xht
new file mode 100644
index 0000000000..862cce0ef2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-008-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: black;
+ border-bottom: green solid 20px;
+ height: 20px;
+ width: 200px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-008.xht
new file mode 100644
index 0000000000..7021afce57
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-008.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom applied to element with display inline</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-008-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-bottom' property applies to elements with a display of inline. However, vertical margins do not have any affect on non-replaced inline elements." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ border-bottom: 1em solid red;
+ font: 20px/1em Ahem;
+ width: 10em;
+ }
+ div div
+ {
+ border-bottom: 1em solid green;
+ display: inline;
+ margin-bottom: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div>
+ <div>XXXXXXXXXX</div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-009-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-009-ref.xht
new file mode 100644
index 0000000000..1cc12e93e6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-009-ref.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: orange;
+ height: 10px;
+ }
+
+ div + div
+ {
+ background-color: blue;
+ margin-top: 50px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is space between the blue and orange lines.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-009.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-009.xht
new file mode 100644
index 0000000000..fe5688fda9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-009.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom applied to element with display block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property applies to elements with a display of block." />
+ <style type="text/css">
+ div
+ {
+ border-bottom: 10px solid blue;
+ }
+ span
+ {
+ border-bottom: 10px solid orange;
+ display: block;
+ margin-bottom: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div>
+ <span></span>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-010.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-010.xht
new file mode 100644
index 0000000000..5f7cf6b207
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-010.xht
@@ -0,0 +1,32 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom applied to element with display list-item</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <meta name="assert" content="The 'margin-bottom' property applies to elements with a display of list-item." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px blue solid;
+ }
+ div div
+ {
+ border-bottom: 10px orange solid;
+ display: list-item;
+ height: 16px;
+ margin-bottom: 50px;
+ margin-left: 1em;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines and the orange line has a marker bullet to its left-hand side. (Note the marker bullet does not need to be aligned with either line.)</p>
+ <div id="wrapper">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-012.xht
new file mode 100644
index 0000000000..9cb67181d2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-012.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom applied to element with display inline-block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property applies to elements with a display of inline-block." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ div div
+ {
+ border-bottom: 10px solid orange;
+ display: inline-block;
+ height: 200px;
+ width: 200px;
+ margin-bottom: 50px;
+ vertical-align: bottom;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-013.xht
new file mode 100644
index 0000000000..73dd92e9d5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-013.xht
@@ -0,0 +1,46 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom applied to element with display table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property applies to elements with a display of table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #table
+ {
+ border-bottom: 10px solid orange;
+ display: table;
+ table-layout: fixed;
+ margin-bottom: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-014.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-014.xht
new file mode 100644
index 0000000000..f038b7931a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-014.xht
@@ -0,0 +1,47 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom applied to element with display inline-table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property applies to elements with a display of inline-table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #table
+ {
+ border-bottom: 10px solid orange;
+ display: inline-table;
+ table-layout: fixed;
+ margin-bottom: 50px;
+ vertical-align: top;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-015.xht
new file mode 100644
index 0000000000..4403a8e587
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-bottom-applies-to-015.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-bottom applied to element with display table-caption</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-bottom' property applies to elements with a display of table-caption." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #test
+ {
+ border-bottom: 10px solid orange;
+ display: table-caption;
+ height: 200px;
+ margin-bottom: 50px;
+ width: 200px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-001-ref.xht
new file mode 100644
index 0000000000..06a9e254c1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-001-ref.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div.ib
+ {
+ display: inline-block;
+ left: 100px;
+ position: relative;
+ width: 100px;
+ }
+
+ div.ib + div.ib
+ {
+ position: relative;
+ left: 300px;
+ }
+
+ div > div {height: 20px;}
+
+ div.blue {background-color: blue;}
+
+ div.orange {background-color: orange;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if the blue and orange stripes have the same horizontal spacing between them.</p>
+
+ <div class="ib">
+ <div class="blue"></div>
+ <div class="orange"></div>
+ </div><div class="ib">
+ <div class="blue"></div>
+ <div class="orange"></div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-001.xht
new file mode 100644
index 0000000000..fd6263dd75
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-001.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - horizontal margins do not collapse</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-001-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="Horizontal margins of element do not collapse." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ }
+ #test span
+ {
+ color: blue;
+ margin: 5em;
+ }
+ span
+ {
+ color: white;
+ }
+ .color1
+ {
+ color: orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if the blue and orange stripes have the same horizontal spacing between them.</p>
+ <div id="test">
+ <span>XXXXX</span><span>XXXXX</span>
+ </div>
+ <div id="reference">
+ <span>XXXXX</span><span class="color1">XXXXX</span><span>XXXXXXXXXX</span><span class="color1">XXXXX</span>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-002-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-002-ref.xht
new file mode 100644
index 0000000000..e85f0a0bda
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-002-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-bottom: green solid 20px;
+ border-top: green solid 20px;
+ height: 40px;
+ width: 100px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-002.xht
new file mode 100644
index 0000000000..15c15afa1b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-002.xht
@@ -0,0 +1,46 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - maximum of the two adjoining margins</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-002-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="When margins collapse the margin is the maximum of the two margin widths." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ width: 5em;
+ }
+ div div
+ {
+ background: green;
+ height: 1em;
+ }
+ #div1
+ {
+ background: url('support/margin-collapse-2em-space.png');
+ height: 4em;
+ }
+ #div2
+ {
+ margin-bottom: 2em;
+ }
+ #div3
+ {
+ margin-top: 1em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2"></div>
+ <div id="div3"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-003-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-003-ref.xht
new file mode 100644
index 0000000000..da1ecd7c33
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-003-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-bottom: orange solid 20px;
+ border-top: blue solid 20px;
+ width: 50px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is no vertical space between the blue and orange stripes.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-003.xht
new file mode 100644
index 0000000000..b93045a0c9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-003.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - negative margins adjoining positive margins</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-003-ref.xht" />
+
+ <meta name="assert" content="Negative margins deduct from the maximum of the adjoining positive margin." />
+ <style type="text/css">
+ div div
+ {
+ height: 20px;
+ width: 50px;
+ }
+ #div1
+ {
+ background: blue;
+ margin-bottom: 2in;
+ }
+ #div2
+ {
+ background: orange;
+ margin-top: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is no vertical space between the blue and orange stripes.</p>
+ <div>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-004-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-004-ref.xht
new file mode 100644
index 0000000000..f3364b48dd
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-004-ref.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-bottom: blue solid 20px;
+ border-top: orange solid 20px;
+ bottom: 20px;
+ position: relative;
+ z-index: -1;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if the orange bar is above the blue bar.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-004.xht
new file mode 100644
index 0000000000..7e6d89702b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-004.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - negative margins deducted from zero</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-004-ref.xht" />
+
+ <meta name="assert" content="Negative margins are deducted from zero if no positive margins are adjoining." />
+ <style type="text/css">
+ div div
+ {
+ height: 20px;
+ }
+ #div1
+ {
+ background: blue;
+ margin-bottom: 0;
+ }
+ #div2
+ {
+ background: orange;
+ margin-top: -40px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if the orange bar is above the blue bar.</p>
+ <div>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-005.xht
new file mode 100644
index 0000000000..470086a94f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-005.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - adjoining margins of non-siblings or ancestors</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-002-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="Adjoining margin boxes generated by elements, that are not related by siblings or ancestors, collapse." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ width: 5em;
+ }
+ #div1
+ {
+ background: url('support/margin-collapse-2em-space.png');
+ height: 4em;
+ }
+ #div3, #div4
+ {
+ background: green;
+ height: 1em;
+ }
+ #div3
+ {
+ margin-bottom: 2em;
+ }
+ #div4
+ {
+ margin-top: 1em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div>
+ <div id="div3"></div>
+ </div>
+ <div id="div4"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-006.xht
new file mode 100644
index 0000000000..68661be42b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-006.xht
@@ -0,0 +1,47 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - floated elements do not collapse margins</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-002-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="A floated box does not collapse its margins with any other box." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ width: 5em;
+ }
+ #div1
+ {
+ background: url('support/margin-collapse-2em-space.png');
+ height: 4em;
+ }
+ div div
+ {
+ background: green;
+ height: 1em;
+ }
+ #div2
+ {
+ margin-bottom: 1em;
+ }
+ #div3
+ {
+ float: left;
+ margin-top: 1em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2"></div>
+ <div id="div3"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-007.xht
new file mode 100644
index 0000000000..49912a9e9b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-007.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - floated elements do not collapse margins with children</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-002-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="In-flow children of a floated element do not collapse margins." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ width: 5em;
+ }
+ #div1
+ {
+ background: url('support/margin-collapse-2em-space.png');
+ min-height: 4em;
+ }
+ div div
+ {
+ background: green;
+ height: 1em;
+ }
+ #div2, #div4
+ {
+ float: left;
+ }
+ #div2, #div3
+ {
+ margin-bottom: 1em;
+ }
+ #div4
+ {
+ margin-top: 1em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2">
+ <div id="div3"></div>
+ </div>
+ <div id="div4"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-008.xht
new file mode 100644
index 0000000000..7b942dc5bb
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-008.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing and elements with 'overflow' set to 'visible'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-002-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="Elements with 'overflow' set to 'visible' collapse margin with in-flow children." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ width: 5em;
+ }
+ div div
+ {
+ height: 1em;
+ }
+ #div1
+ {
+ background: url('support/margin-collapse-2em-space.png') left -1em;
+ border-top: 1em solid green;
+ }
+ #div2
+ {
+ margin-top: 2em;
+ overflow: visible;
+ }
+ #div3
+ {
+ background: green;
+ margin-top: 2em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2">
+ <div id="div3"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-009.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-009.xht
new file mode 100644
index 0000000000..6dbcdadf94
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-009.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing and elements with 'overflow' set to 'hidden'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="../reference/ref-if-there-is-no-red.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="Elements with 'overflow' set to 'hidden' do not collapse margin with in-flow children." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ height: 5em;
+ width: 5em;
+ }
+ #div1
+ {
+ height: 2em;
+ margin-top: 2em;
+ overflow: hidden;
+ }
+ #div2
+ {
+ height: 1em;
+ background: red;
+ margin-top: 2em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-010-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-010-ref.xht
new file mode 100644
index 0000000000..bb9d59a051
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-010-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ height: 40px;
+ margin-top: 40px;
+ overflow: scroll;
+ width: 100px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-010.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-010.xht
new file mode 100644
index 0000000000..fee8309310
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-010.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing and elements with 'overflow' set to 'scroll'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="Elements with 'overflow' set to 'scroll' do not collapse margin with in-flow children." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ height: 5em;
+ width: 5em;
+ }
+ #div1
+ {
+ height: 2em;
+ margin-top: 2em;
+ overflow: scroll;
+ }
+ #div2
+ {
+ background: red;
+ height: 1em;
+ margin-top: 2em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-011.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-011.xht
new file mode 100644
index 0000000000..552e004291
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-011.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing and elements with 'overflow' set to 'auto'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="Elements with 'overflow' set to 'auto' do not collapse margin with in-flow children." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ height: 5em;
+ width: 5em;
+ }
+ #div1
+ {
+ height: 2em;
+ margin-top: 2em;
+ overflow: auto;
+ }
+ #div2
+ {
+ background: red;
+ height: 1em;
+ margin-top: 2em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-012.xht
new file mode 100644
index 0000000000..1111ea8828
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-012.xht
@@ -0,0 +1,44 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - absolute positioning and siblings</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="Absolutely positioned boxes do not collapse margins with siblings." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ #div1
+ {
+ background: url('support/margin-collapse-2em-space.png') left -1em;
+ border-top: 1em solid green;
+ font: 20px/1em Ahem;
+ height: 3em;
+ width: 5em;
+ }
+ div div
+ {
+ height: 1em;
+ margin-top: 1em;
+ width: 5em;
+ }
+ #div2
+ {
+ height: 0;
+ }
+ #div3
+ {
+ background: green;
+ position: absolute;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2"></div>
+ <div id="div3"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-013-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-013-ref.xht
new file mode 100644
index 0000000000..5b2fd7de2a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-013-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-bottom: green solid 40px;
+ height: 40px;
+ width: 100px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-013.xht
new file mode 100644
index 0000000000..8a98034b86
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-013.xht
@@ -0,0 +1,47 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - absolute positioning with children elements</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-013-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="Absolutely positioned boxes do not collapse margins with any in-flow children." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ width: 5em;
+ }
+ #div1
+ {
+ background: url('support/margin-collapse-013.png');
+ height: 4em;
+ }
+ #div2, #div3
+ {
+ margin-top: 2em;
+ }
+ #div2
+ {
+ background: green;
+ position: absolute;
+ }
+ #div3
+ {
+ height: 0;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2">
+ <div id="div3"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-014.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-014.xht
new file mode 100644
index 0000000000..61b22b558d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-014.xht
@@ -0,0 +1,47 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - inline-block elements as siblings</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-002-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="Inline-block elements that are siblings do not collapse their margins." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/0 Ahem;
+ width: 5em;
+ }
+ #div1
+ {
+ background: url('support/margin-collapse-2em-space.png');
+ height: 4em;
+ }
+ div div
+ {
+ background: green;
+ display: inline-block;
+ height: 1em;
+ }
+ #div2
+ {
+ margin-bottom: 1em;
+ }
+ #div3
+ {
+ margin-top: 1em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2"></div>
+ <div id="div3"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-015.xht
new file mode 100644
index 0000000000..7ea9985683
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-015.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - inline-block child does not collapse margins with parent</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-14 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-002-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="An element that is set in inline-block and its children set to inline-block do not collapse margins." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/0 Ahem;
+ width: 5em;
+ }
+ #div1
+ {
+ background: url('support/margin-collapse-2em-space.png');
+ height: 4em;
+ }
+ #div2, #div3
+ {
+ display: inline-block;
+ margin-bottom: 1em;
+ }
+ #div3, #div4
+ {
+ background: green;
+ height: 1em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2">
+ <div id="div3"></div>
+ </div>
+ <div id="div4"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-015a.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-015a.xht
new file mode 100644
index 0000000000..edc38696d6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-015a.xht
@@ -0,0 +1,66 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Test: Margin collapsing - inline-block child does not collapse margins with parent</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+ <link rel="reviewer" title="Arron Eicholz" href="arronei(at)gmail.com" /> <!-- 2013-07-30 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-002-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="An element with its display set to 'inline-block' does not collapse its margins with its children." />
+
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css"><![CDATA[
+ div
+ {
+ font: 20px/1 Ahem;
+ width: 5em;
+ }
+
+ div#wrapper
+ {
+ background-image: url("support/margin-collapse-2em-space.png");
+ height: 4em;
+ }
+
+ div#inline-block
+ {
+ display: inline-block;
+ margin-bottom: 2.5em;
+ vertical-align: bottom;
+ }
+
+ div#block-child-of-inline-block
+ {
+ display: block;
+ margin-bottom: 3.5em;
+ margin-top: 0.5em;
+ }
+
+ div#wrapper div {background-color: green;}
+
+ div#inline-block, div#block-child-of-inline-block {height: 0.5em;}
+
+ div#following-sibling-after-inline-block {height: 1em;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div id="wrapper">
+ <div id="inline-block">
+ <div id="block-child-of-inline-block"></div>
+ </div>
+ <div id="following-sibling-after-inline-block"></div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-016.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-016.xht
new file mode 100644
index 0000000000..9daa8d1420
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-016.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - top/bottom margins adjoining collapse through</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-002-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="When top and bottom margins are adjoining margins collapse through that element." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ width: 5em;
+ }
+ #div1
+ {
+ background: url('support/margin-collapse-2em-space.png');
+ height: 4em;
+ }
+ #div2, #div4
+ {
+ background:green;
+ height: 1em;
+ }
+ #div3
+ {
+ background: red;
+ height: 0;
+ }
+ #div2, #div3
+ {
+ margin-bottom: 2em;
+ }
+ #div3, #div4
+ {
+ margin-top: 2em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2"></div>
+ <div id="div3"></div>
+ <div id="div4"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-017-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-017-ref.xht
new file mode 100644
index 0000000000..17587f0eb7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-017-ref.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: blue;
+ height: 20px;
+ margin-top: 60px;
+ width: 60px;
+ }
+
+ div + div
+ {
+ border-top: black solid 3px;
+ height: auto;
+ margin-top: auto;
+ width: auto;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if the blue stripe is touching the line and there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-017.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-017.xht
new file mode 100644
index 0000000000..303a3376e1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-017.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - parent edge and element edge are the same when margins collapse</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-017-ref.xht" />
+
+ <meta name="assert" content="When the top margin of a child box collapses with the top margin of its parent, then the margin-top edge of such child box is the same as the parent's and their respective content should be 'sitting' at the parent's border-bottom (in the testcase, the black line) assuming the same height value and the same padding-bottom value for the parent and its child box." />
+ <style type="text/css">
+ #div1
+ {
+ border-bottom: black solid 3px;
+ }
+ div div
+ {
+ height: 20px;
+ margin-top: 60px;
+ width: 60px;
+ }
+ #div2
+ {
+ background: red;
+ }
+ #div3
+ {
+ background: blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if the blue stripe is touching the line and there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2">
+ <div id="div3"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-019.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-019.xht
new file mode 100644
index 0000000000..006c8971bd
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-019.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - elements that collapse margins have to effect on positions of other elements that also have margins that are collapsing</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-002-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="Positions of elements that have been collapsed through (empty elements) have no effect on positions of other elements whose margins are being collapsed." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ width: 5em;
+ }
+ div div
+ {
+ height: 1em;
+ }
+ #div1
+ {
+ background: url('support/margin-collapse-2em-space.png') left -1em;
+ border-top: 1em solid green;
+ }
+ #div2
+ {
+ background: red;
+ }
+ #div3
+ {
+ background: red;
+ height: 0;
+ margin-top: 2em;
+ margin-bottom: 2em;
+ }
+ #div4
+ {
+ background: green;
+ margin-top: 2em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2">
+ <div id="div3"></div>
+ <div id="div4"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-020-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-020-ref.xht
new file mode 100644
index 0000000000..beaa5c9686
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-020-ref.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 40px 0px;}
+
+ div
+ {
+ background-color: green;
+ height: 20px;
+ width: 100px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <div></div>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-020.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-020.xht
new file mode 100644
index 0000000000..4268bbdf2c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-020.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing with the root element</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-020-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="For HTML pages the html element does not collapse its margins with other elements." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ html
+ {
+ background: url('support/margin-collapse-020.png') 0 -1em no-repeat;
+ font: 20px/1em Ahem;
+ margin-top: 1em;
+ }
+ body
+ {
+ margin: 0;
+ }
+ div
+ {
+ background: green;
+ margin-top: 1em;
+ height: 1em;
+ width: 5em;
+ }
+ p
+ {
+ font: 12pt serif;
+ }
+ </style>
+ </head>
+ <body>
+ <div></div>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-021.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-021.xht
new file mode 100644
index 0000000000..304c75170e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-021.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing with the 'body' element</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <!--
+ http://lists.w3.org/Archives/Public/public-css-testsuite/2016Apr/0000.html
+ -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-020-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="The 'body' element's margins collapse." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ body
+ {
+ background: url('support/margin-collapse-020.png') no-repeat;
+ font: 20px/1em Ahem;
+ margin: 2em 0 0;
+ }
+ div
+ {
+ background: green;
+ margin-top: 2em;
+ height: 1em;
+ width: 5em;
+ }
+ p
+ {
+ font: 12pt serif;
+ }
+ </style>
+ </head>
+ <body>
+ <div></div>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-022.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-022.xht
new file mode 100644
index 0000000000..4b80359301
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-022.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - adjoining block boxes</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-002-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="Bottom margin of an in-flow block-level element is always adjoining to the top margin of its next in-flow block-level sibling." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ width: 5em;
+ }
+ div div
+ {
+ background: green;
+ height: 1em;
+ }
+ #div1
+ {
+ background: url('support/margin-collapse-2em-space.png');
+ }
+ #div2
+ {
+ margin-bottom: 2em;
+ }
+ #div3
+ {
+ margin-top: 2em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2"></div>
+ <div id="div3"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-025.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-025.xht
new file mode 100644
index 0000000000..d2ea30ddbc
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-025.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - in-flow block-level margins with an element 'height' of 'auto' and 'max-height' and 'min-height'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-002-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="The bottom margin of an in-flow block-level element(#div2) with a 'height' of 'auto' will adjoin to its last in-flow block-level child's (#div3) bottom margin if such auto-height in-flow block-level element has no bottom padding and no bottom border. The bottom margins will then collapse." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ width: 5em;
+ }
+ #div1
+ {
+ background: url('support/margin-collapse-2em-space.png') 0 0;
+ height: 4em;
+ }
+ #div2
+ {
+ background: red;
+ height: auto;
+ min-height: 0.5em;
+ max-height: 2em;
+ }
+ #div3, #div4
+ {
+ background: green;
+ height: 1em;
+ }
+ #div2, #div3
+ {
+ margin-bottom: 2em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2">
+ <div id="div3"></div>
+ </div>
+ <div id="div4"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-026.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-026.xht
new file mode 100644
index 0000000000..fa74b334d5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-026.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - in-flow block-level margins with an element 'height' of 'auto' and 'min-height' of zero</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-002-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="An element's margins are adjoining and can collapse if the 'min-height' is zero, if it has no top or bottom borders and no top or bottom padding, if it has a 'height' of zero or 'auto', if it has no line boxes and if all of its in-flow children's margins are adjoining." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ width: 5em;
+ }
+ #div1
+ {
+ background: url('support/margin-collapse-2em-space.png');
+ height: 4em;
+ }
+ #div3
+ {
+ background: red;
+ height: auto;
+ min-height: 0;
+ }
+ #div2, #div5
+ {
+ background: green;
+ height: 1em;
+ }
+ #div3, #div4
+ {
+ margin-bottom: 2em;
+ margin-top: 2em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2"></div>
+ <div id="div3">
+ <div id="div4"></div>
+ </div>
+ <div id="div5"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-028.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-028.xht
new file mode 100644
index 0000000000..810639c4ca
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-028.xht
@@ -0,0 +1,60 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing is based on used values of 'padding', 'margin' and 'border'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-002-ref.xht" />
+
+ <meta name="flags" content="ahem image" />
+ <meta name="assert" content="Collapsing of margins is based on the used values of 'padding', 'margin' and 'border'." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1em Ahem;
+ width: 5em;
+ }
+ #div3, #div5
+ {
+ background: green;
+ height: 1em;
+ }
+ #div1
+ {
+ background: url('support/margin-collapse-2em-space.png');
+ }
+ #div2
+ {
+ border: 0 solid red;
+ width: 0;
+ }
+ #div3
+ {
+ margin-bottom: 2em;
+ }
+ #div4
+ {
+ border: inherit;
+ margin: 50%;
+ padding: 50%;
+ }
+ #div5
+ {
+ margin-top: 2em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2">
+ <div id="div3"></div>
+ <div id="div4">
+ <div id="div5"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-029.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-029.xht
new file mode 100644
index 0000000000..0eea0036f3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-029.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - position of top border edge for elements that collapse margins with parents not participating in margin collapsing</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <meta name="assert" content="When margins collapse through empty elements and the parent element is not participating in margin collapsing then the position of the elements top border should be in the same position as if the element had a top border specified." />
+ <style type="text/css">
+ div
+ {
+ width: 5em;
+ }
+ #div1
+ {
+ border-top: 1em solid black;
+ }
+ #div2
+ {
+ margin-top: 2em;
+ margin-bottom: 4em;
+ position: absolute;
+ background: black;
+ height: 1em;
+ }
+ #div3
+ {
+ height: 0;
+ margin-top: 2em;
+ margin-bottom: 2em;
+ }
+ #div4
+ {
+ margin-top: 3em;
+ margin-bottom: 2em;
+ border-top: 1em solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there are three evenly-spaced black boxes stacked on the page.</p>
+ <div id="div1">
+ <div id="div2">
+ <div id="div3"></div>
+ <div id="div4"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-030.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-030.xht
new file mode 100644
index 0000000000..ffb8215d61
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-030.xht
@@ -0,0 +1,46 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin collapsing - position of top border edge for elements that collapse margins with parents whose bottom margin only participates in margin collapsing</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <meta name="assert" content="When margins collapse through empty elements and only the parent element's bottom margin is participating in margin collapsing then the position of the elements top border should be in the same position as if the element had a top border specified." />
+ <style type="text/css">
+ div
+ {
+ width: 5em;
+ }
+ #div1
+ {
+ border-top: 1em solid black;
+ }
+ #div2
+ {
+ margin-top: 2em;
+ margin-bottom: 4em;
+ border-top: 1em solid black;
+ }
+ #div3
+ {
+ height: 0;
+ margin-top: 2em;
+ margin-bottom: 2em;
+ }
+ #div4
+ {
+ margin-top: 2em;
+ margin-bottom: 2em;
+ border-top: 1em solid black;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there are three evenly-spaced black boxes stacked on the page.</p>
+ <div id="div1">
+ <div id="div2">
+ <div id="div3"></div>
+ <div id="div4"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-032.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-032.xht
new file mode 100644
index 0000000000..284f006cc5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-032.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Test: margin collapsing - resolving vertical padding percentage</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <meta content="Adjoining of vertical (top and bottom) margins must be determined only after resolving percentage padding-top and padding-bottom values." name="assert" />
+
+ <style type="text/css"><![CDATA[
+ div#grand-parent-block-container
+ {
+ background-color: red;
+ border: black solid 3px;
+ /* Such border prevents margin collapsing with the body vertical margins */
+ }
+
+ div#parent-block-container
+ {
+ background-color: green;
+ color: white;
+ padding: 2%;
+ }
+
+ div#child-block {margin: 100px 0px;}
+
+ /*
+ In this testcase, div#child-block's vertical (top and bottom)
+ margins should collapse with div#parent-block-container's vertical
+ (top and bottom) margins because div#child-block has no used
+ padding-top and no used padding-bottom. On the other hand,
+ div#parent-block-container's vertical (top and bottom) margins
+ should NOT collapse with div#grand-parent-block-container's vertical
+ (top and bottom) margins because div#parent-block-container, after
+ resolving percentage values, has an used padding-top value and an used
+ padding-bottom value.
+ */
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <div id="grand-parent-block-container">
+ <div id="parent-block-container">
+ <div id="child-block">
+ Test passes if there is <strong>no red</strong>.
+ </div>
+ </div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-037-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-037-ref.xht
new file mode 100644
index 0000000000..deb7f507a5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-037-ref.xht
@@ -0,0 +1,32 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p {margin: 8px 0px 0px;}
+
+ div
+ {
+ background-color: green;
+ height: 100px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green rectangle across the page and <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-037.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-037.xht
new file mode 100644
index 0000000000..87efa907f0
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-037.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Test: Collapsing margins - margin-bottom of the last in-flow child block collapsing with its parent min-height block's bottom margin</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+ <link rel="author" title="Bruno Fassino" href="http://www.brunildo.org/" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-037-ref.xht" />
+
+ <meta content="The 'min-height' of a parent block element should have no influence over whether such parent block element's bottom margin is adjoining to its last child's bottom margin. In such situation, the bottom margin of the parent block element and the bottom margin of its last child should collapse as long as such parent block element has no bottom padding and has no bottom border." name="assert" />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p {margin: 8px 0px 0px;}
+
+ div#reference-overlapping-green
+ {
+ background-color: green;
+ height: 100px;
+ left: 8px;
+ position: absolute;
+ right: 8px;
+ }
+
+ #test-overlapped-red
+ {
+ background-color: red;
+ min-height: 50px;
+ }
+
+ #last-child
+ {
+ height: 100px;
+ margin-bottom: 100px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green rectangle across the page and <strong>no red</strong>.</p>
+
+ <div id="reference-overlapping-green"></div>
+
+ <div id="test-overlapped-red">
+ <div id="last-child"></div>
+ </div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-038-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-038-ref.xht
new file mode 100644
index 0000000000..0cee229cd0
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-038-ref.xht
@@ -0,0 +1,32 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p {margin: 8px 0px 0px;}
+
+ div
+ {
+ background-color: green;
+ height: 200px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a tall filled green rectangle across the page and <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-038.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-038.xht
new file mode 100644
index 0000000000..ada2e31cf7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-038.xht
@@ -0,0 +1,73 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Test: Collapsing margins - margin-bottom of the last in-flow child block collapsing with its max-height parent block's bottom margin</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+ <link rel="author" title="Bruno Fassino" href="http://www.brunildo.org/" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
+ <link rel="match" href="margin-collapse-038-ref.xht" />
+
+ <meta content="The 'max-height' of a parent block element should have no influence over whether such parent block element's bottom margin is adjoining to its last child's bottom margin. In such situation, the bottom margin of the parent block element and the bottom margin of its last child should collapse as long as such parent block element has no bottom padding and has no bottom border." name="assert" />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p {margin: 8px 0px 0px;}
+
+ div#reference-overlapped-red
+ {
+ background-color: red;
+ height: 200px;
+ left: 8px;
+ position: absolute;
+ right: 8px;
+ z-index: -1;
+ }
+
+ div#green-grand-parent
+ {
+ background-color: green;
+ border-bottom: green solid 1px;
+ }
+
+ div#parent-with-max-height
+ {
+ margin-bottom: 0px;
+ max-height: 99px;
+ }
+
+ div#last-child
+ {
+ height: 300px;
+ /*
+ The height of parent-with-max-height is constrained by
+ its max-height which is smaller than this last-child height
+ */
+ margin-bottom: 100px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a tall filled green rectangle across the page and <strong>no red</strong>.</p>
+
+ <div id="reference-overlapped-red"></div>
+
+ <div id="green-grand-parent">
+ <div id="parent-with-max-height">
+ <div id="last-child"></div>
+ </div>
+ </div>
+
+ <!--
+ #last-child's margin-bottom should collapse with #parent-with-max-height's margin-bottom: max(0px, 100px) = 100px
+ -->
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-039.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-039.xht
new file mode 100644
index 0000000000..e093faf979
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-039.xht
@@ -0,0 +1,90 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Test: margin collapsing - clear with child margin</title>
+
+ <!--
+ Inspired by
+ http://test.csswg.org/suites/css2.1/20110323/html4/c5525-fltmult-000.htm
+ -->
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+ <link rel="reviewer" title="Arron Eicholz" href="arronei(at)gmail.com" /> <!-- 2013-07-30 -->
+ <link rel="bookmark" href="http://lists.w3.org/Archives/Public/public-css-testsuite/2012Jan/0022.html" title="[RC6] c5525-fltmult-000 imprecise and failed by several browsers" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" title="8.3.1 Collapsing margins" />
+ <link rel="match" href="../reference/ref-filled-green-100px-square.xht" />
+
+ <meta name="assert" content="An element on which 'clear' is set to a value other than 'none' can have its own margin-top collapse with its first inflow block-level child as long as no line boxes, no clearance, no padding and no border separate them." />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p {margin: 1em 0em;}
+
+ div#overlapped-red
+ {
+ background-color: red;
+ height: 100px;
+ position: absolute;
+ width: 100px;
+ z-index: -1;
+ }
+
+ div#floated-left
+ {
+ background-color: green;
+ color: green;
+ float: left;
+ font: 1em/1.25 serif;
+ padding: 15px;
+ /*
+
+ 15px : padding-top
+ +
+ 20px : line box height
+ +
+ 15px : padding-bottom
+ =====
+ 50px
+
+ */
+ width: 70px;
+ }
+
+ div#cleared-left {clear: left;}
+
+ div#child-of-cleared-left
+ {
+ background-color: green;
+ color: green;
+ height: 50px;
+ margin-top: 50px;
+ width: 100px;
+ }
+
+ /*
+ The idea is to have div#cleared-left's margin-top collapse
+ with div#child-of-cleared-left's margin-top. The margin collapsing
+ should occur before calculating clearance.
+ */
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+
+ <div id="overlapped-red"></div>
+
+ <div id="floated-left">flt lef</div>
+
+ <div id="cleared-left">
+ <div id="child-of-cleared-left">chld clr</div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-040.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-040.xht
new file mode 100644
index 0000000000..a9a3b0ca63
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-040.xht
@@ -0,0 +1,101 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Test: margin collapsing - clear with child margin</title>
+
+ <!--
+ Inspired by
+ http://test.csswg.org/suites/css2.1/20110323/html4/c5525-fltmult-000.htm
+ -->
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+ <link rel="reviewer" title="Arron Eicholz" href="arronei(at)gmail.com" /> <!-- 2013-07-30 -->
+ <link rel="bookmark" href="http://lists.w3.org/Archives/Public/public-css-testsuite/2012Jan/0022.html" title="[RC6] c5525-fltmult-000 imprecise and failed by several browsers" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" title="8.3.1 Collapsing margins" />
+ <link rel="match" href="../reference/ref-filled-green-100px-square.xht" />
+
+ <meta name="assert" content="An element on which 'clear' is set to a value other than 'none' can have its own margin-top collapse with its first inflow block-level child as long as no line boxes, no clearance, no padding and no border separate them." />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p {margin: 1em 0em;}
+
+ div#overlapped-red
+ {
+ background-color: red;
+ height: 100px;
+ position: absolute;
+ width: 100px;
+ z-index: -1;
+ }
+
+ div#floated-left
+ {
+ background-color: green;
+ color: green;
+ float: left;
+ font: 1em/1.25 serif;
+ padding: 15px;
+ /*
+
+ 15px : padding-top
+ +
+ 20px : line box height
+ +
+ 15px : padding-bottom
+ =====
+ 50px
+
+ */
+ width: 70px;
+ }
+
+ div#cleared-left {clear: left;}
+
+ table
+ {
+ border-collapse: separate;
+ border-spacing: 0px;
+ margin-top: 50px;
+ }
+
+ td
+ {
+ background-color: green;
+ color: green;
+ height: 50px;
+ padding: 0px;
+ width: 100px;
+ }
+
+ /*
+ The idea is to have div#cleared-left's margin-top collapse
+ with the table's margin-top. The margin collapsing
+ should occur before calculating clearance.
+ */
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+
+ <div id="overlapped-red"></div>
+
+ <div id="floated-left">flt lef</div>
+
+ <div id="cleared-left">
+ <table>
+ <tr>
+ <td>td</td>
+ </tr>
+ </table>
+ </div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-041.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-041.xht
new file mode 100644
index 0000000000..742d93f4a6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-041.xht
@@ -0,0 +1,107 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Test: margin collapsing - clear with descendants margins</title>
+
+ <!--
+ Inspired by
+ http://test.csswg.org/suites/css2.1/20110323/html4/c5525-fltmult-000.htm
+ -->
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+ <link rel="reviewer" title="Arron Eicholz" href="arronei(at)gmail.com" /> <!-- 2013-07-30 -->
+ <link rel="bookmark" href="http://lists.w3.org/Archives/Public/public-css-testsuite/2012Jan/0022.html" title="[RC6] c5525-fltmult-000 imprecise and failed by several browsers" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" title="8.3.1 Collapsing margins" />
+ <link rel="match" href="../reference/ref-filled-green-100px-square.xht" />
+
+ <meta name="assert" content="An element on which 'clear' is set to a value other than 'none' can have its own margin-top collapse with the margin-top of its first inflow block-level child (which may also be the resulting combined margin of its own subtree of descendants) as long as no line boxes, no clearance, no padding and no border separate them." />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p {margin: 1em 0em;}
+
+ div#overlapped-red
+ {
+ background-color: red;
+ height: 100px;
+ position: absolute;
+ width: 100px;
+ z-index: -1;
+ }
+
+ div#floated-left
+ {
+ background-color: green;
+ color: green;
+ float: left;
+ font: 1em/1.25 serif;
+ padding: 15px;
+ /*
+
+ 15px : padding-top
+ +
+ 20px : line box height
+ +
+ 15px : padding-bottom
+ =====
+ 50px
+
+ */
+ width: 70px;
+ }
+
+ div#cleared-left {clear: left;}
+
+ div#child-of-cleared-left
+ {
+ background-color: red;
+ margin-top: 50px;
+ width: 100px;
+ }
+
+ div#grandchild-of-cleared-left
+ {
+ background-color: red;
+ margin-top: 40px;
+ }
+
+ div#grand-grandchild-of-cleared-left
+ {
+ background-color: green;
+ color: green;
+ height: 50px;
+ margin-top: 30px;
+ }
+
+ /*
+ The idea is to have div#cleared-left's margin-top collapse
+ with div#child-of-clear-left's margin-top. The margin
+ collapsing of margin-tops of descendants of div#cleared-left
+ should occur before calculating clearance.
+ */
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+
+ <div id="overlapped-red"></div>
+
+ <div id="floated-left">flt lft</div>
+
+ <div id="cleared-left">
+ <div id="child-of-cleared-left">
+ <div id="grandchild-of-cleared-left">
+ <div id="grand-grandchild-of-cleared-left">ggchld</div>
+ </div>
+ </div>
+ </div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-101-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-101-ref.xht
new file mode 100644
index 0000000000..c0f9054dbc
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-101-ref.xht
@@ -0,0 +1,62 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ table
+ {
+ border: solid 3px;
+ border-spacing: 0;
+ font-size: 50px;
+ }
+
+ td
+ {
+ background-color: orange;
+ padding: 0;
+ }
+
+ div {margin: 1em 0;}
+
+ .a {background-color: yellow;}
+
+ .b {background-color: lime;}
+
+ .c {background-color: aqua;}
+
+ .d {background-color: blue;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a stack of multi-colored horizontal bars with no red.</p>
+
+ <table>
+ <tr>
+ <td>
+ <div class="d">
+ <div class="a">A</div>
+ <div class="b">B</div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="d">
+ <div class="a">A</div>
+ <div class="b">B</div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ </tr>
+ </table>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-101.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-101.xht
new file mode 100644
index 0000000000..047131b342
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-101.xht
@@ -0,0 +1,46 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/001.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-101-ref.xht" />
+
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid 3px; }
+ td { background: orange; padding: 0; }
+ div { margin: 1em 0; }
+ .a { background: yellow; }
+ .b { background: lime; }
+ .c { background: aqua; }
+ .d { background: blue; }
+ .red { background: red; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a stack of multi-colored horizontal bars with no red.</p>
+ <table>
+ <tr>
+ <td class="test">
+ <div class="d">
+ <div class="red"><div class="red"><div class="a">A</div></div><div class="red"></div></div>
+ <div class="red"></div>
+ <div class="red"><div class="red"></div></div>
+ <div class="red"><div class="b"><div class="red"></div>B</div></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td class="control">
+ <div class="d">
+ <div class="a">A</div>
+ <div class="b">B</div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-102.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-102.xht
new file mode 100644
index 0000000000..a7f2e54134
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-102.xht
@@ -0,0 +1,27 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: absolutely positioned</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/002.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="../reference/ref-filled-green-100px-square.xht" />
+
+ <style type="text/css">
+ div {font-size: 20px;}
+ div.test { background: green; position: absolute; }
+ div.test div { background: red; margin: 5em 2.5em; }
+ div.control { height: 5em; width: 5em; background: red; position: absolute; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+ <div class="control"></div>
+ <div class="test">
+ <div></div>
+ </div>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-103-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-103-ref.xht
new file mode 100644
index 0000000000..5ed730b731
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-103-ref.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: green;
+ height: 80px;
+ position: absolute;
+ top: 64px;
+ width: 80px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-103.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-103.xht
new file mode 100644
index 0000000000..bf84658135
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-103.xht
@@ -0,0 +1,26 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: fixed positioned</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/003.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-103-ref.xht" />
+
+ <style type="text/css">
+ div.test { background: green; position: fixed; top: 4em; }
+ div.test div { background: red; margin: 5em 2.5em; }
+ div.control { height: 5em; width: 5em; background: red; position: fixed; top: 4em; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+ <div class="control"></div>
+ <div class="test">
+ <div></div>
+ </div>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-104.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-104.xht
new file mode 100644
index 0000000000..8df9a90384
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-104.xht
@@ -0,0 +1,27 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: floats</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/004.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="../reference/ref-filled-green-100px-square.xht" />
+
+ <style type="text/css">
+ div {font-size: 20px;}
+ div.test { background: green; float: left; }
+ div.test div { background: red; margin: 5em 2.5em; }
+ div.control { height: 5em; width: 5em; margin: 0 0 -5em 0; background: red; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+ <div class="control"></div>
+ <div class="test">
+ <div></div>
+ </div>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-105.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-105.xht
new file mode 100644
index 0000000000..c8b596ba32
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-105.xht
@@ -0,0 +1,47 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (relatively positioned)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/005.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-101-ref.xht" />
+
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid 3px; }
+ td { background: orange; padding: 0; }
+ div { margin: 1em 0; }
+ .test div { position: relative; }
+ .a { background: yellow; }
+ .b { background: lime; }
+ .c { background: aqua; }
+ .d { background: blue; }
+ .red { background: red; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a stack of multi-colored horizontal bars with no red.</p>
+ <table>
+ <tr>
+ <td class="test">
+ <div class="d">
+ <div class="red"><div class="red"><div class="a">A</div></div><div class="red"></div></div>
+ <div class="red"></div>
+ <div class="red"><div class="red"></div></div>
+ <div class="red"><div class="b"><div class="red"></div>B</div></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td class="control">
+ <div class="d">
+ <div class="a">A</div>
+ <div class="b">B</div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-106-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-106-ref.xht
new file mode 100644
index 0000000000..69415315dc
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-106-ref.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ table
+ {
+ border: solid 3px;
+ border-spacing: 0;
+ font-size: 50px;
+ }
+
+ td {padding: 0;}
+
+ div {width: 2em;}
+
+ .c {border-top: orange solid 1em;}
+
+ .a {border-top: yellow solid 1em;}
+
+ .b {border-top: lime solid 1em;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a stack of 5 bands which are <strong>from top to bottom: orange, yellow, orange, lime, orange</strong> and with no red.</p>
+
+ <table>
+ <tr>
+ <td>
+ <div class="c"></div>
+ <div class="a"></div>
+ <div class="c"></div>
+ <div class="b"></div>
+ <div class="c"></div>
+ </td>
+ </tr>
+ </table>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-106.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-106.xht
new file mode 100644
index 0000000000..a1d5536221
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-106.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (simple)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/006.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-106-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ table { border-spacing: 0; font: 50px/1 Ahem; border: solid 3px; background: red; }
+ td { padding: 0; }
+ /* test */
+ .test { background: orange; }
+ .test div { margin: 1em 0; background: red; }
+ .test .a { color: yellow; }
+ .test .b { color: lime; }
+ /* control */
+ .control div { width: 1em; }
+ .control .c { border-top: 1em orange solid; }
+ .control .a { border-top: 1em yellow solid; }
+ .control .b { border-top: 1em lime solid; }
+ /* control control */
+ .red { background: red; height: 1em; width: 10em; border: solid; }
+ .orange { border-top: 1em orange solid; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a stack of 5 bands which are <strong>from top to bottom: orange, yellow, orange, lime, orange</strong> and with no red.</p>
+ <table>
+ <tr>
+ <td class="test">
+ <div class="a">X</div>
+ <div class="b">X</div>
+ </td>
+ <td class="control">
+ <div class="c"></div>
+ <div class="a"></div>
+ <div class="c"></div>
+ <div class="b"></div>
+ <div class="c"></div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-107.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-107.xht
new file mode 100644
index 0000000000..9ed65fd6ff
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-107.xht
@@ -0,0 +1,53 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (used height)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="author" title="Elika J. Etemad" href="http://fantasai.inkedblade.net/contact"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/007.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <meta name="assert" content="This tests that emptiness is based on the
+ computed values of height."/>
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid white; background: red; }
+ td { padding: 0; }
+
+ /* colors */
+ .test, .control { background: lime; }
+ .a { background: aqua; color: aqua; }
+ .b { background: yellow; color: yellow; }
+
+ /* test */
+ .test .a { margin: 0 0 1em 0; }
+ .test .c { margin: 1em 0 1em 0;
+ height: 0.04px; }
+ .test .b { margin: 1em 0 0 0; }
+
+ /* control */
+ .control .a { margin: 0 0 2em; }
+ .control .c { height: 0.04px; }
+ </style>
+ </head>
+ <body>
+ <p>The pattern below should be a stack of three perfect rectangles with no red.</p>
+ <table>
+ <tr>
+ <td>
+ <div class="test">
+ <div class="a">A</div>
+ <div class="c"></div>
+ <div class="b">B</div>
+ </div>
+ </td>
+ <td>
+ <div class="control">
+ <div class="a">A</div>
+ <div class="c"></div>
+ <div class="b">B</div>
+ </div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-108.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-108.xht
new file mode 100644
index 0000000000..8f3796fe29
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-108.xht
@@ -0,0 +1,53 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (used border)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="author" title="Elika J. Etemad" href="http://fantasai.inkedblade.net/contact"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/008.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <meta name="assert" content="This tests that emptiness is based on the
+ computed values of border."/>
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid white; background: red; }
+ td { padding: 0; }
+
+ /* colors */
+ .test, .control { background: lime; }
+ .a { background: aqua; color: aqua; }
+ .b { background: yellow; color: yellow; }
+
+ /* test */
+ .test .a { margin: 0 0 1em 0; }
+ .test .c { margin: 1em 0 1em 0;
+ border-bottom: solid lime 0.04px; }
+ .test .b { margin: 1em 0 0 0; }
+
+ /* control */
+ .control .a { margin: 0 0 2em; }
+ .control .c { border-bottom: solid lime 0.04px; }
+ </style>
+ </head>
+ <body>
+ <p>The pattern below should be a stack of three perfect rectangles with no red.</p>
+ <table>
+ <tr>
+ <td>
+ <div class="test">
+ <div class="a">A</div>
+ <div class="c"></div>
+ <div class="b">B</div>
+ </div>
+ </td>
+ <td>
+ <div class="control">
+ <div class="a">A</div>
+ <div class="c"></div>
+ <div class="b">B</div>
+ </div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-109.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-109.xht
new file mode 100644
index 0000000000..736e0bf847
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-109.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (used padding)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="author" title="Elika J. Etemad" href="http://fantasai.inkedblade.net/contact"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/009.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <meta name="assert" content="This tests that emptiness is based on the
+ computed values of padding."/>
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid white; background: red; }
+ td { padding: 0; }
+
+ /* colors */
+ .test, .control { background: lime; }
+ .a { background: aqua; color: aqua; }
+ .b { background: yellow; color: yellow; }
+
+ /* test */
+ .test .a { margin: 0 0 1em 0; }
+ .test .c { margin: 1em 0 1em 0;
+ padding-bottom: 0.04px; }
+ .test .b { margin: 1em 0 0 0; }
+
+ /* control */
+ .control .a { margin: 0 0 2em; }
+ .control .c { padding-bottom: 0.04px; }
+ </style>
+ </head>
+ <body>
+ <p>The pattern below should be a stack of three perfect rectangles with no red.</p>
+ <table>
+ <tr>
+ <td>
+ <div class="test">
+ <div class="a">A</div>
+ <div class="c"></div>
+ <div class="b">B</div>
+ </div>
+ </td>
+ <td>
+ <div class="control">
+ <div class="a">A</div>
+ <div class="b">B</div>
+ </div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-110-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-110-ref.xht
new file mode 100644
index 0000000000..a2bd043b7c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-110-ref.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ table
+ {
+ background-color: orange;
+ border: solid 3px;
+ border-spacing: 0px;
+ table-layout: fixed;
+ width: 256px;
+ }
+
+ td {padding: 50px 0px;}
+
+ div#yellow
+ {
+ border-top: yellow solid 50px;
+ margin-bottom: 50px;
+ }
+
+ div#lime {border-top: lime solid 50px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a stack of 5 bands which are <strong>from top to bottom: orange, yellow, orange, lime, orange</strong>.</p>
+
+ <table>
+ <tr>
+ <td>
+ <div id="yellow"></div>
+ <div id="lime"></div>
+ </td>
+ </tr>
+ </table>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-110.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-110.xht
new file mode 100644
index 0000000000..097e22dd13
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-110.xht
@@ -0,0 +1,62 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (simple combinations)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/010.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-110-ref.xht" />
+
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid 3px; background: orange; }
+ td { padding: 0; }
+ div { height: 1em; width: 1em; }
+ .a { background: yellow; }
+ .b { background: lime; }
+ /* column 1 */
+ .t1 .a { margin: 1em 0 1em; }
+ .t1 .b { margin: 1em 0 1em; }
+ /* column 2 */
+ .t2 .a { margin: 1em 0 1em; }
+ .t2 .b { margin: 0em 0 1em; }
+ /* column 3 */
+ .t3 .a { margin: 1em 0 0em; }
+ .t3 .b { margin: 1em 0 1em; }
+ /* column 4 */
+ .t4 .a { margin: 1em 0 2em; }
+ .t4 .b { margin: -1em 0 1em; }
+ /* column 5 */
+ .t5 .a { margin: 1em 0 -1em; }
+ .t5 .b { margin: 2em 0 1em; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a stack of 5 bands which are <strong>from top to bottom: orange, yellow, orange, lime, orange</strong>.</p>
+ <table>
+ <tr>
+ <td class="t1">
+ <div class="a"></div>
+ <div class="b"></div>
+ </td>
+ <td class="t2">
+ <div class="a"></div>
+ <div class="b"></div>
+ </td>
+ <td class="t3">
+ <div class="a"></div>
+ <div class="b"></div>
+ </td>
+ <td class="t4">
+ <div class="a"></div>
+ <div class="b"></div>
+ </td>
+ <td class="t5">
+ <div class="a"></div>
+ <div class="b"></div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-111.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-111.xht
new file mode 100644
index 0000000000..daaf38b050
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-111.xht
@@ -0,0 +1,63 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (simple combinations with collapse-through)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/011.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-110-ref.xht" />
+
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid 3px; background: orange; }
+ td { padding: 0; }
+ .a, .b { height: 1em; width: 1em; }
+ .a { background: yellow; }
+ .b { background: lime; }
+ .c { background: red; margin: 1em 0 1em; }
+ .t1 .a { margin: 1em 0 1em; }
+ .t1 .b { margin: 1em 0 1em; }
+ .t2 .a { margin: 1em 0 1em; }
+ .t2 .b { margin: 0em 0 1em; }
+ .t3 .a { margin: 1em 0 0em; }
+ .t3 .b { margin: 1em 0 1em; }
+ .t4 .a { margin: 1em 0 2em; }
+ .t4 .b { margin: -1em 0 1em; }
+ .t5 .a { margin: 1em 0 -1em; }
+ .t5 .b { margin: 2em 0 1em; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a stack of 5 bands which are <strong>from top to bottom: orange, yellow, orange, lime, orange</strong>.</p>
+ <table>
+ <tr>
+ <td class="t1">
+ <div class="a"></div>
+ <div class="c"></div>
+ <div class="b"></div>
+ </td>
+ <td class="t2">
+ <div class="a"></div>
+ <div class="c"></div>
+ <div class="b"></div>
+ </td>
+ <td class="t3">
+ <div class="a"></div>
+ <div class="c"></div>
+ <div class="b"></div>
+ </td>
+ <td class="t4">
+ <div class="a"></div>
+ <div class="c"></div>
+ <div class="b"></div>
+ </td>
+ <td class="t5">
+ <div class="a"></div>
+ <div class="c"></div>
+ <div class="b"></div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-112.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-112.xht
new file mode 100644
index 0000000000..09396c4e13
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-112.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (simple)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/012.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-106-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ table { border-spacing: 0; font: 50px/1 Ahem; border: solid 3px; background: red; }
+ td { padding: 0; }
+ /* test */
+ .test { background: orange; }
+ .test div { margin: 1em 0; background: red; height: 1em; width: 1em; }
+ .test .a { background: yellow; }
+ .test .b { background: lime; }
+ /* control */
+ .control div { width: 1em; }
+ .control .c { border-top: 1em orange solid; }
+ .control .a { border-top: 1em yellow solid; }
+ .control .b { border-top: 1em lime solid; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a stack of 5 bands which are <strong>from top to bottom: orange, yellow, orange, lime, orange</strong> and with no red.</p>
+ <table>
+ <tr>
+ <td class="test">
+ <div class="a"></div>
+ <div class="b"></div>
+ </td>
+ <td class="control">
+ <div class="c"></div>
+ <div class="a"></div>
+ <div class="c"></div>
+ <div class="b"></div>
+ <div class="c"></div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-113-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-113-ref.xht
new file mode 100644
index 0000000000..856246795d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-113-ref.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ table
+ {
+ border: solid 3px;
+ border-spacing: 0;
+ font-size: 50px;
+ }
+
+ td {padding: 0;}
+
+ div {width: 3em;}
+
+ .a {border-top: yellow solid 1em;}
+
+ .b {border-top: orange solid 2em;}
+
+ .c {border-top: lime solid 1em;}
+
+ .d {border-top: aqua solid 1em;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a stack of 4 bands which are <strong>from top to bottom: yellow, orange, lime, aqua</strong> and with no red.</p>
+
+ <table>
+ <tr>
+ <td>
+ <div class="a"></div>
+ <div class="b"></div>
+ <div class="c"></div>
+ <div class="d"></div>
+ </td>
+ </tr>
+ </table>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-113.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-113.xht
new file mode 100644
index 0000000000..ffba934aa3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-113.xht
@@ -0,0 +1,58 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (position of collapsed-through element)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/013.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-113-ref.xht" />
+
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid 3px; background: red; }
+ td { padding: 0; }
+ /* test */
+ .test { background: orange; width: 1em; }
+ .test .a { background: yellow; margin: 0 0 1em 0; height: 1em; }
+ .test .b { background: red; margin: 2em 0 0 0; position: relative; }
+ .test .c { background: aqua; margin: 3em 0 0 0; height: 1em; }
+ .test .d { background: lime; margin: 0; height: 1em; width: 100%; }
+ .test .pos { position: absolute; }
+ .test .float { float: left; }
+ /* control */
+ .control div { width: 1em; }
+ .control .a { border-top: 1em yellow solid; }
+ .control .b { border-top: 2em orange solid; }
+ .control .c { border-top: 1em lime solid; }
+ .control .d { border-top: 1em aqua solid; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a stack of 4 bands which are <strong>from top to bottom: yellow, orange, lime, aqua</strong> and with no red.</p>
+ <table>
+ <tr>
+ <td class="test">
+ <div class="a"></div>
+ <div class="b">
+ <div class="d pos"></div>
+ </div>
+ <div class="c"></div>
+ </td>
+ <td class="test">
+ <div class="a"></div>
+ <div class="b">
+ <div class="d float"></div>
+ </div>
+ <div class="c"></div>
+ </td>
+ <td class="control">
+ <div class="a"></div>
+ <div class="b"></div>
+ <div class="c"></div>
+ <div class="d"></div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-114-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-114-ref.xht
new file mode 100644
index 0000000000..afc660157c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-114-ref.xht
@@ -0,0 +1,53 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ table
+ {
+ border: solid 3px;
+ border-spacing: 0;
+ font-size: 50px;
+ }
+
+ td {padding: 0;}
+
+ div {width: 3em;}
+
+ .a {border-top: yellow solid 1em;}
+
+ .b {border-top: orange solid 3em;}
+
+ .c {border-top: lime solid 1em;}
+
+ .d {border-top: aqua solid 1em;}
+
+ .e { border-top: orange solid 1em; }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a stack of 5 bands which are <strong>from top to bottom: yellow, orange, lime, aqua, orange</strong> with no red.</p>
+
+ <table>
+ <tr>
+ <td>
+ <div class="a"></div>
+ <div class="b"></div>
+ <div class="c"></div>
+ <div class="d"></div>
+ <div class="e"></div>
+ </td>
+ </tr>
+ </table>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-114.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-114.xht
new file mode 100644
index 0000000000..3f90f8d954
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-114.xht
@@ -0,0 +1,60 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (position of collapsed-through element)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/014.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-114-ref.xht" />
+
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid 3px; background: red; }
+ td { padding: 0; vertical-align: top;}
+ /* test */
+ .test { background: orange; width: 1em; }
+ .test .a { background: yellow; margin: 0 0 1em 0; height: 1em; }
+ .test .b { background: red; margin: 2em 0 0 0; position: relative; }
+ .test .c { background: lime; margin: 3em 0 0 0; height: 1em; }
+ .test .d { background: aqua; margin: 2em 0 1em 0; height: 1em; width: 100%; }
+ .test .pos { position: absolute; }
+ .test .float { float: left; }
+ /* control */
+ .control div { width: 1em; }
+ .control .a { border-top: 1em yellow solid; }
+ .control .b { border-top: 3em orange solid; }
+ .control .c { border-top: 1em lime solid; }
+ .control .d { border-top: 1em aqua solid; }
+ .control .e { border-top: 1em orange solid; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a stack of 5 bands which are <strong>from top to bottom: yellow, orange, lime, aqua, orange</strong> with no red.</p>
+ <table>
+ <tr>
+ <td class="test">
+ <div class="a"></div>
+ <div class="b">
+ <div class="d pos"></div>
+ </div>
+ <div class="c"></div>
+ </td>
+ <td class="test">
+ <div class="a"></div>
+ <div class="b">
+ <div class="d float"></div>
+ </div>
+ <div class="c"></div>
+ </td>
+ <td class="control">
+ <div class="a"></div>
+ <div class="b"></div>
+ <div class="c"></div>
+ <div class="d"></div>
+ <div class="e"></div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-115-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-115-ref.xht
new file mode 100644
index 0000000000..1773df921d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-115-ref.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ table
+ {
+ border: solid 3px;
+ border-spacing: 0;
+ font-size: 50px;
+ }
+
+ td {padding: 0;}
+
+ div {width: 2em;}
+
+ .a {border-top: yellow solid 1em;}
+
+ .b {border-top: orange solid 2em;}
+
+ .c {border-top: lime solid 1em;}
+
+ .d {border-top: aqua solid 1em;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a stack of 4 bands which are <strong>from top to bottom: yellow, orange, lime, aqua</strong> and with no red.</p>
+
+ <table>
+ <tr>
+ <td>
+ <div class="a"></div>
+ <div class="b"></div>
+ <div class="c"></div>
+ <div class="d"></div>
+ </td>
+ </tr>
+ </table>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-115.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-115.xht
new file mode 100644
index 0000000000..95f54be93a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-115.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<!-- This test is basically the same as 013.html --><head>
+ <title>CSS Test: Margin Collapsing: in flow (position of collapsed-through element)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/015.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-115-ref.xht" />
+
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid 3px; background: red; }
+ td { padding: 0; }
+ /* test */
+ .test { background: orange; width: 1em; }
+ .test .a { background: yellow; margin: 0 0 1em 0; height: 1em; }
+ .test .b { background: red; margin: 2em 0 0 0; }
+ .test .c { background: aqua; margin: 3em 0 0 0; height: 1em; }
+ .test .d { background: lime; margin: 0; position: absolute; height: 1em; width: 1em; }
+ /* control */
+ .control div { width: 1em; }
+ .control .a { border-top: 1em yellow solid; }
+ .control .b { border-top: 2em orange solid; }
+ .control .c { border-top: 1em lime solid; }
+ .control .d { border-top: 1em aqua solid; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a stack of 4 bands which are <strong>from top to bottom: yellow, orange, lime, aqua</strong> and with no red.</p>
+ <table>
+ <tr>
+ <td class="test">
+ <div class="a"></div>
+ <div class="b">
+ <div class="d"></div>
+ </div>
+ <div class="c"></div>
+ </td>
+ <td class="control">
+ <div class="a"></div>
+ <div class="b"></div>
+ <div class="c"></div>
+ <div class="d"></div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-116.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-116.xht
new file mode 100644
index 0000000000..fc00058680
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-116.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<!-- This is similar to tests 013 to 015 --><head>
+ <title>CSS Test: Margin Collapsing: in flow (position of collapsed-through element)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/016.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-115-ref.xht" />
+
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid 3px; background: red; }
+ td { padding: 0; }
+ /* test */
+ .test { background: orange; width: 1em; }
+ .test .a { background: yellow; margin: 0 0 1em 0; height: 1em; }
+ .test .b { background: red; margin: 1em 0 0 0; }
+ .test .c { background: lime; margin: 2em 0 1em 0; height: 1em; }
+ .test .d { background: aqua; position: absolute; height: 1em; width: 1em; margin: 2em 0 0 0; }
+ /* control */
+ .control div { width: 1em; }
+ .control .a { border-top: 1em yellow solid; }
+ .control .b { border-top: 2em orange solid; }
+ .control .c { border-top: 1em lime solid; }
+ .control .d { border-top: 1em aqua solid; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a stack of 4 bands which are <strong>from top to bottom: yellow, orange, lime, aqua</strong> and with no red.</p>
+ <table>
+ <tr>
+ <td>
+ <div class="test">
+ <div class="a"></div>
+ <div class="b">
+ <div class="d"></div>
+ </div>
+ <div class="c"></div>
+ </div>
+ </td>
+ <td class="control">
+ <div class="a"></div>
+ <div class="b"></div>
+ <div class="c"></div>
+ <div class="d"></div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-117.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-117.xht
new file mode 100644
index 0000000000..cae482535c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-117.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (height)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/017.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid; background: red; }
+ td { padding: 0; width: 1em; }
+ /* test */
+ .test .a { background: red; margin: 0; height: 1em; }
+ .test .aa { background: yellow; margin: 0 0 1em 0; height: 1em; }
+ .test .b { background: lime; margin: 0; height: 1em; }
+ /* control */
+ .control .a { border-top: 1em yellow solid; }
+ .control .b { border-top: 1em lime solid; }
+ </style>
+ </head>
+ <body>
+ <p>The following square should contain exactly two bands, one yellow, one lime, with no red visible.</p>
+ <table>
+ <tr>
+ <td class="test">
+ <div class="a">
+ <div class="aa"></div>
+ </div>
+ <div class="b"></div>
+ </td>
+ <td class="control">
+ <div class="a"></div>
+ <div class="b"></div>
+ </td>
+ </tr>
+ </table>
+ <p>This test is meaningless if you don't pass <a href="margin-collapse-118">test 118</a>.</p>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-118.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-118.xht
new file mode 100644
index 0000000000..90283bab1b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-118.xht
@@ -0,0 +1,44 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (height)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/018.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid; background: red; }
+ td { padding: 0; width: 1em; }
+ /* test */
+ .test .outer { background: orange; }
+ .test .a { background: red; margin: 0; height: auto; }
+ .test .aa { background: yellow; margin: 0 0 1em 0; height: 1em; }
+ .test .b { background: lime; margin: 0; height: 1em; }
+ /* control */
+ .control .a { border-top: 1em yellow solid; }
+ .control .b { border-top: 1em orange solid; }
+ .control .c { border-top: 1em lime solid; }
+ </style>
+ </head>
+ <body>
+ <p>The following box should contain exactly three bands, one yellow, one orange, and one lime, with <strong>absolutely no red visible</strong>.</p>
+ <table>
+ <tr>
+ <td class="test">
+ <div class="outer">
+ <div class="a">
+ <div class="aa"></div>
+ </div>
+ <div class="b"></div>
+ </div>
+ </td>
+ <td class="control">
+ <div class="a"></div>
+ <div class="b"></div>
+ <div class="c"></div>
+ </td>
+ </tr>
+ </table>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-119.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-119.xht
new file mode 100644
index 0000000000..13e5517f01
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-119.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (height)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/019.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid; background: red; }
+ td { padding: 0; width: 1em; }
+
+ div.container, div.after { background: lime; }
+
+ .a .container { height: 1.1em; }
+ .a .sized { height: 1.0em; margin: 0 0 1em 0; }
+ .a .after { height: 0.9em; }
+
+ .b .container { height: 1.0em; }
+ .b .sized { height: 1.0em; margin: 0 0 1em 0; }
+ .b .after { height: 1.0em; }
+
+ .c .container { height: 0.9em; }
+ .c .sized { height: 1.0em; margin: 0 0 1em 0; }
+ .c .after { height: 1.1em; }
+
+ </style>
+ </head>
+ <body>
+ <p>There should be no red on this page.</p>
+ <table>
+ <tr>
+ <td class="a">
+ <div class="container">
+ <div class="sized"></div>
+ </div>
+ <div class="after"></div>
+ </td>
+ <td class="b">
+ <div class="container">
+ <div class="sized"></div>
+ </div>
+ <div class="after"></div>
+ </td>
+ <td class="c">
+ <div class="container">
+ <div class="sized"></div>
+ </div>
+ <div class="after"></div>
+ </td>
+ </tr>
+ </table>
+ <p>See also: <a href="http://www.hixie.ch/tests/adhoc/css/box/block/height/002.html">prerequisite</a>.</p>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-120.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-120.xht
new file mode 100644
index 0000000000..831f81f372
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-120.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (height)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/020.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid; background: red; }
+ td { padding: 0; width: 1em; }
+
+ div { background: lime; }
+
+ .a .container { height: 2.1em; }
+ .a .sized { height: 1.0em; margin: 0 0 1em 0; }
+ .a .after { height: 0.9em; }
+
+ .b .container { height: 2.0em; }
+ .b .sized { height: 1.0em; margin: 0 0 1em 0; }
+ .b .after { height: 1.0em; }
+
+ .c .container { height: 1.9em; }
+ .c .sized { height: 1.0em; margin: 0 0 1em 0; }
+ .c .after { height: 1.1em; }
+
+ </style>
+ </head>
+ <body>
+ <p>There should be no red on this page.</p>
+ <table>
+ <tr>
+ <td class="a">
+ <div class="container">
+ <div class="sized"></div>
+ </div>
+ <div class="after"></div>
+ </td>
+ <td class="b">
+ <div class="container">
+ <div class="sized"></div>
+ </div>
+ <div class="after"></div>
+ </td>
+ <td class="c">
+ <div class="container">
+ <div class="sized"></div>
+ </div>
+ <div class="after"></div>
+ </td>
+ </tr>
+ </table>
+ <p>See also: <a href="019.html">prerequisite</a>.</p>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-126.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-126.xht
new file mode 100644
index 0000000000..ba9b4aad27
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-126.xht
@@ -0,0 +1,21 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: negative margins (easy)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/026.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ .container { background: red; height: auto; border-top: 1em red solid; border-bottom: 1em lime solid; }
+ .test { border-top: 1em solid lime; margin-top: -1em; }
+ </style>
+ </head>
+ <body>
+ <p>There should be no red below.</p>
+ <div class="container">
+ <div class="test"></div>
+ </div>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-127.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-127.xht
new file mode 100644
index 0000000000..e72645ac1e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-127.xht
@@ -0,0 +1,23 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: negative margins (easy)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/027.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ .container { background: red; height: auto; border-top: 1em lime solid; border-bottom: 1em lime solid; }
+ .red { border-top: 1em solid red; }
+ .lime { border-top: 1em solid lime; margin-top: -1em; }
+ </style>
+ </head>
+ <body>
+ <p>There should be no red below.</p>
+ <div class="container">
+ <div class="red"></div>
+ <div class="lime"></div>
+ </div>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-128.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-128.xht
new file mode 100644
index 0000000000..afe6ca4c6b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-128.xht
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: negative margins (easy)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/028.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ .container { background: red; height: auto; border: 1em lime solid; }
+ .a { margin-top: 1em; margin-bottom: 1em; }
+ .b { margin-top: 1em; margin-bottom: 1em; }
+ .c { margin-top: 1em; margin-bottom: 1em; }
+ .d { margin-top: 1em; margin-bottom: 1em; }
+ .e { margin-top: 1em; margin-bottom: -1em; }
+ .f { margin-top: 1em; margin-bottom: 1em; }
+ </style>
+ </head>
+ <body>
+ <p>There should be no red below.</p>
+ <div class="container">
+ <div class="a">
+ <div class="b"> </div>
+ <div class="c"> </div>
+ </div>
+ <div class="d">
+ <div class="e"> </div>
+ <div class="f"> </div>
+ </div>
+ </div>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-129.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-129.xht
new file mode 100644
index 0000000000..5a871b6c2f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-129.xht
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: negative margins (easy)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/029.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ .container { background: red; height: auto; border: 1em lime solid; }
+ .a { margin-top: -1em; margin-bottom: 1em; }
+ .b { margin-top: 1em; margin-bottom: 1em; }
+ .c { margin-top: 1em; margin-bottom: 1em; }
+ .d { margin-top: 1em; margin-bottom: 1em; }
+ .e { margin-top: 1em; margin-bottom: 1em; }
+ .f { margin-top: 1em; margin-bottom: 1em; }
+ </style>
+ </head>
+ <body>
+ <p>There should be no red below.</p>
+ <div class="container">
+ <div class="a">
+ <div class="b"> </div>
+ <div class="c"> </div>
+ </div>
+ <div class="d">
+ <div class="e"> </div>
+ <div class="f"> </div>
+ </div>
+ </div>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-130-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-130-ref.xht
new file mode 100644
index 0000000000..781debdb41
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-130-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: lime;
+ border: black solid medium;
+ height: 2.5em;
+ width: 6.25em;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a small filled bright green rectangle with a black border and <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-130.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-130.xht
new file mode 100644
index 0000000000..860ff83e9e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-130.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: basic overflow test</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-04-08 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/030.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-130-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ .test { border: solid; background: red; width: 5em; font: 1.25em/1em Ahem; }
+ .test .a { height: 0; margin: 0 0 1em 0; background: red; color: lime; }
+ .test .b { height: 1em; margin: 1em 0 0 0; background: lime; }
+ </style>
+ </head>
+ <body>
+
+ <p>Test passes if there is a small filled bright green rectangle with a black border and <strong>no red</strong>.</p>
+ <div class="test">
+ <p class="a">XXXXX</p>
+ <p class="b"></p>
+ </div>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-131-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-131-ref.xht
new file mode 100644
index 0000000000..9da7bb98e9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-131-ref.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ table
+ {
+ background-color: green;
+ border-spacing: 0px;
+ margin: 40px auto auto 40px;
+ table-layout: fixed;
+ }
+
+ col {width: 40px;}
+
+ td {padding: 0px;}
+
+ img {vertical-align: top;}
+ ]]>
+ </style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a big square green H.</p>
+
+ <table>
+ <col></col><col></col><col></col>
+ <tr><td></td><td><img src="support/swatch-white.png" width="40" height="40" alt="Image download support must be enabled" /></td><td></td></tr>
+ <tr><td></td><td><img src="support/swatch-green.png" width="40" height="40" alt="Image download support must be enabled" /></td><td></td></tr>
+ <tr><td></td><td><img src="support/swatch-white.png" width="40" height="40" alt="Image download support must be enabled" /></td><td></td></tr>
+ </table>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-131.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-131.xht
new file mode 100644
index 0000000000..1731556384
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-131.xht
@@ -0,0 +1,27 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow text (simple)</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-06-27 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/031.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-131-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ .test { margin: 1em; background: green; font: 40px/1 Ahem; width: 3em; }
+ .test div { color: white; margin: 1em; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a big square green H.</p>
+ <div class="test">
+ <div>X</div>
+ <div>X</div>
+ </div>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-132.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-132.xht
new file mode 100644
index 0000000000..4628eb47f0
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-132.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: float positioning</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/032.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ table, td { padding: 0; border-spacing: 0; }
+ .comparator { border-spacing: 1em; }
+ .test, .control { border: solid; background: lime; }
+
+ .test .container { display: block; margin: 1em 0 0 0; width: 8em; background: red; }
+ .test .float { float: left; margin: 0; height: 1em; width: 8em; background: yellow; }
+ .test .block { display: block; margin: 2em 0 0 0; height: 1em; background: red; }
+
+ .control .lime { border-top: 2em solid lime; width: 8em; }
+ .control .yellow { border-top: 1em solid yellow; }
+
+ </style>
+ </head>
+ <body>
+ <p>The following two rectangles should be identical.</p>
+ <table class="comparator">
+ <tr>
+ <td class="test">
+ <div class="container">
+ <div class="float"> </div>
+ <div class="block"> </div>
+ </div>
+ </td>
+ <td class="control">
+ <div class="lime"> </div>
+ <div class="yellow"> </div>
+ </td>
+ </tr>
+ </table>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-133.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-133.xht
new file mode 100644
index 0000000000..39f0185ab6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-133.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: float positioning</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/033.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ table, td { padding: 0; border-spacing: 0; }
+ .comparator { border-spacing: 1em; }
+ .test, .control { border: solid; background: lime; }
+
+ .test .top { display: block; margin: 0; height: 1em; width: 8em; background: yellow; }
+ .test .container { display: block; margin: 1em 0 0 0; width: 8em; background: red; }
+ .test .float { float: left; margin: 0; height: 1em; width: 8em; background: yellow; }
+ .test .block { display: block; margin: 2em 0 0 0; height: 1em; background: red; }
+
+ .control .lime { border-top: 2em solid lime; width: 8em; }
+ .control .yellow { border-top: 1em solid yellow; }
+ </style>
+ </head>
+ <body>
+ <p>The following two rectangles should be identical.</p>
+ <table class="comparator">
+ <tr>
+ <td class="test">
+
+ <div class="top"> </div>
+ <div class="container">
+ <div class="float"> </div>
+ <div class="block"> </div>
+ </div>
+
+ </td>
+ <td class="control">
+ <div class="yellow"> </div>
+ <div class="lime"> </div>
+ <div class="yellow"> </div>
+ </td>
+ </tr>
+ </table>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-137-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-137-ref.xht
new file mode 100644
index 0000000000..508f70e96e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-137-ref.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: green;
+ height: 20px;
+ margin-top: 100px;
+ width: 100px;
+ }
+ ]]>
+ </style>
+
+ </head>
+
+ <body>
+
+ <div></div>
+
+ <p>Test passes if there is no red above.</p>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-137.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-137.xht
new file mode 100644
index 0000000000..3f95f1a60d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-137.xht
@@ -0,0 +1,32 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: margins on relative boxes</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-06-27 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/037.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-137-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div { font: 20px/1 Ahem, sans-serif; }
+ .relative { position: relative; margin: 0 0 5em 0; }
+ .absolute { position: absolute; margin: 0; top: 0; left: 0; color: green; }
+ .static { position: static; margin: 0; color: red; }
+ </style>
+ </head>
+ <body>
+ <div class="relative">
+ <div class="absolute">
+ XXXXX
+ </div>
+ </div>
+ <div class="static">
+ XXXXX
+ </div>
+ <p>Test passes if there is no red above.</p>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-138.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-138.xht
new file mode 100644
index 0000000000..e67b8ce654
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-138.xht
@@ -0,0 +1,32 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: margins on relative boxes</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-06-27 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/038.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-137-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div { font: 20px/1 Ahem, sans-serif; }
+ .relative { position: relative; margin: 0 0 5em 0; }
+ .absolute { position: absolute; margin: 0; top: 0; left: 0; color: green; }
+ .static { position: static; margin: 3em 0 0 0; color: red; }
+ </style>
+ </head>
+ <body>
+ <div class="relative">
+ <div class="absolute">
+ XXXXX
+ </div>
+ </div>
+ <div class="static">
+ XXXXX
+ </div>
+ <p>Test passes if there is no red above.</p>
+
+</body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-139.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-139.xht
new file mode 100644
index 0000000000..f4d982675a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-139.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: top margins</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/039.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ .a { margin: 0; background: red; }
+ .b { margin: 2em 0 0 0; background: red; }
+ .c { margin: 1em 0 0 0; background: red; }
+ .d { margin: 0; background: green; color: white; }
+ </style>
+ </head>
+ <body>
+ <p>There should be no red below.</p>
+ <div class="a">
+ <div class="b">
+ <div class="c">
+ <div class="d">
+ This line should be green.
+ </div>
+ </div>
+ </div>
+ </div>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-140.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-140.xht
new file mode 100644
index 0000000000..8e2671508f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-140.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: top margins</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/040.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ .a { margin: 0; background: red; }
+ .b { margin: 2em 0 0 0; background: red; }
+ .c { margin: 0; background: red; }
+ .d { margin: 1em 0 0 0; background: green; color: white; }
+ </style>
+ </head>
+ <body>
+ <p>There should be no red below.</p>
+ <div class="a">
+ <div class="b">
+ <div class="c">
+ <div class="d">
+ This line should be green.
+ </div>
+ </div>
+ </div>
+ </div>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-141.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-141.xht
new file mode 100644
index 0000000000..ad7bb041d1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-141.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: top margins</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/041.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ .test { background: aqua; margin: 0; width: 6em; border: solid; }
+ .test .a { height: 1em; background: fuchsia; margin: 0; }
+ .test .b { background: red; margin: 0; }
+ .test .c { float: left; height: 1em; width: 3em; background: orange; margin: 0; }
+ .test .d { height: 1em; background: yellow; margin: 1em 0 0 0; }
+ .control { width: 6em; border: solid; }
+ .control .a { border-top: fuchsia 1em solid; }
+ .control .b { border-top: aqua 1em solid; }
+ .control .c { border-left: orange 3em solid; border-right: yellow 3em solid; height: 1em; }
+ </style>
+ </head>
+ <body>
+ <p>The two boxes below should look identical.</p>
+ <table>
+ <tr>
+ <td>
+ <div class="test">
+ <div class="a"></div>
+ <div class="b">
+ <div class="c"></div>
+ <div class="d"></div>
+ </div>
+ </div>
+ </td>
+ <td>
+ <div class="control">
+ <div class="a"></div>
+ <div class="b"></div>
+ <div class="c"></div>
+ </div>
+ </td>
+ </tr>
+ </table>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-143.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-143.xht
new file mode 100644
index 0000000000..87066bc4d8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-143.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Placement of out-of-flow object in elements that have been collapsed through</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/043.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ .outer { border-top: solid white; border-bottom: solid 1em red; background: green; }
+ .top { height: 1em; background: white; }
+ .float { height: 1em; float: left; background: white; width: 100%; }
+ .bottom { margin-bottom: 1em; }
+ </style>
+ </head>
+ <body>
+ <p>There should be a single green band below, and no red anywhere.</p>
+ <div class="outer">
+ <div class="top"> <!-- 1em vertical white space --> </div>
+ <div class="bottom"> <!-- 1em bottom margin collapses to here -->
+ <div class="bottom"> <!-- 1em bottom margin collapses with above -->
+ <div class="float"> </div> <!-- overlaps the bottom border -->
+ </div> <!-- nothing here, bottom margin collapsed upwards -->
+ </div> <!-- nothing here, bottom margin collapsed upwards -->
+ </div> <!-- 1em bottom red border, coincident with white float above -->
+
+
+
+</body>
+</html><!-- note. this test assumes that we accept the following proposed changes:
+ http://lists.w3.org/Archives/Member/w3c-css-wg/2003AprJun/0347.html
+ -->
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-145.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-145.xht
new file mode 100644
index 0000000000..4d01b81263
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-145.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Placement of out-of-flow object in elements that have been collapsed through</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/045.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ td { width: 3em; padding: 0; }
+
+ .test { background: fuchsia; }
+ .a { margin: 0; height: 1em; background: aqua; }
+ .b { margin: 0; background: red; }
+ .c { margin: 0; background: red; }
+ .d { margin: 0; background: red; }
+ .e { margin: 0; background: purple; height: 1em; float: left; width: 100%; }
+ .f { margin: 0 0 1em 0; background: red; }
+
+ .control { background: red; }
+ .aqua { border-top: solid 1em aqua; }
+ .fuchsia { border-top: solid 1em fuchsia; }
+ .purple { border-top: solid 1em purple; }
+ </style>
+ </head>
+ <body>
+ <p>The following two columns should look the same.</p>
+ <table>
+ <tr>
+ <td class="test">
+ <div class="a"> </div>
+ <div class="b">
+ <div class="c"> </div>
+ <div class="d">
+ <div class="e"> </div>
+ </div>
+ <div class="f"> </div>
+ </div>
+ </td>
+ <td class="control">
+ <div class="aqua"></div>
+ <div class="fuchsia"></div>
+ <div class="purple"></div>
+ </td>
+ </tr>
+ </table>
+
+
+
+</body>
+</html><!-- note. this test assumes that we accept the following proposed changes:
+ http://lists.w3.org/Archives/Member/w3c-css-wg/2003AprJun/0347.html
+ -->
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-146.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-146.xht
new file mode 100644
index 0000000000..a5bfd76488
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-146.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Placement of out-of-flow object in elements that have been collapsed through</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/046.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ td { width: 3em; padding: 0; }
+
+ .test { background: fuchsia; }
+ .a { margin: 0; height: 1em; background: aqua; }
+ .b { margin: 0; background: red; }
+ .c { margin: 0; background: red; }
+ .d { margin: 0; background: red; }
+ .f { margin: 0 0 1em 0; background: red; }
+ .e { margin: 0; background: purple; height: 1em; float: left; width: 100%; }
+
+ .control { background: red; }
+ .aqua { border-top: solid 1em aqua; }
+ .fuchsia { border-top: solid 1em fuchsia; }
+ .purple { border-top: solid 1em purple; }
+ </style>
+ </head>
+ <body>
+ <p>The following two columns should look the same.</p>
+ <table>
+ <tr>
+ <td class="test">
+ <div class="a"> </div>
+ <div class="b">
+ <div class="c"> </div>
+ <div class="d"> </div>
+ <div class="f"> </div>
+ <div class="e"> </div>
+ </div>
+ </td>
+ <td class="control">
+ <div class="aqua"></div>
+ <div class="fuchsia"></div>
+ <div class="purple"></div>
+ </td>
+ </tr>
+ </table>
+
+
+
+</body>
+</html><!-- note. this test assumes that we accept the following proposed changes:
+ http://lists.w3.org/Archives/Member/w3c-css-wg/2003AprJun/0347.html
+ -->
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-147.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-147.xht
new file mode 100644
index 0000000000..0b6bf07648
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-147.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Placement of out-of-flow object in elements that have been collapsed through</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/047.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ td { width: 3em; padding: 0; }
+
+ .test { background: fuchsia; }
+ .a { margin: 0; height: 1em; background: aqua; }
+ .b { margin: 0; background: red; }
+ .e { margin: 0; background: purple; height: 1em; float: left; width: 100%; }
+ .c { margin: 0; background: red; }
+ .d { margin: 0; background: red; }
+ .f { margin: 0 0 1em 0; background: red; }
+
+ .control { background: red; }
+ .aqua { border-top: solid 1em aqua; }
+ .fuchsia { border-top: solid 1em fuchsia; }
+ .purple { border-top: solid 1em purple; }
+ </style>
+ </head>
+ <body>
+ <p>The following two columns should look the same.</p>
+ <table>
+ <tr>
+ <td class="test">
+ <div class="a"> </div>
+ <div class="b">
+ <div class="e"> </div>
+ <div class="c"> </div>
+ <div class="d"> </div>
+ <div class="f"> </div>
+ </div>
+ </td>
+ <td class="control">
+ <div class="aqua"></div>
+ <div class="fuchsia"></div>
+ <div class="purple"></div>
+ </td>
+ </tr>
+ </table>
+
+
+
+</body>
+</html><!-- note. this test assumes that we accept the following proposed changes:
+ http://lists.w3.org/Archives/Member/w3c-css-wg/2003AprJun/0347.html
+ -->
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-148.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-148.xht
new file mode 100644
index 0000000000..bb0c56f7a4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-148.xht
@@ -0,0 +1,54 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Placement of out-of-flow object in elements that have been collapsed through</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/048.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ td { width: 3em; padding: 0; }
+
+ .test { background: yellow; }
+ .a { margin: 0; height: 1em; background: orange; }
+ .b { margin: 0; background: aqua; height: 2em; }
+ .c { margin: 0; background: red; }
+ .d { margin: 0; background: red; }
+ .e { margin: 0; background: lime; height: 1em; float: left; width: 100%; }
+ .f { margin: 0 0 1em 0; background: red; }
+
+ .control { background: red; }
+ .orange { border-top: solid 1em orange; }
+ .yellow { border-top: solid 1em yellow; }
+ .lime { border-top: solid 1em lime; }
+ .aqua { border-top: solid 1em aqua; }
+ </style>
+ </head>
+ <body>
+ <p>The following two columns should look the same.</p>
+ <table>
+ <tr>
+ <td class="test">
+ <div class="a"> </div>
+ <div class="b">
+ <div class="c"> </div>
+ <div class="d">
+ <div class="e"> </div>
+ </div>
+ <div class="f"> </div>
+ </div>
+ </td>
+ <td class="control">
+ <div class="orange"></div>
+ <div class="yellow"></div>
+ <div class="lime"></div>
+ <div class="aqua"></div>
+ </td>
+ </tr>
+ </table>
+
+
+
+</body>
+</html><!-- note. this test assumes that we accept the following proposed changes:
+ http://lists.w3.org/Archives/Member/w3c-css-wg/2003AprJun/0347.html
+ -->
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-151.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-151.xht
new file mode 100644
index 0000000000..403d0be058
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-151.xht
@@ -0,0 +1,22 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Magical Margins should not be magical in strict mode</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/051.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ .test { border: solid 0.5em; background: yellow; float: left; margin: 1em; font-size: 2em; }
+ .test p { background: teal; color: white; }
+ .control { border-width: 0.25em 0.5em; }
+ .control div { border-top: solid 0.25em; }
+ </style>
+ </head>
+ <body>
+ <p>The next two blocks should be identical.</p>
+ <div class="test"><p>TEST</p></div>
+ <div class="test control"><div></div><p>TEST</p><div></div></div>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-154.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-154.xht
new file mode 100644
index 0000000000..f8f7e35c5d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-154.xht
@@ -0,0 +1,98 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: effect of margins near float on collapsing-through</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/054.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+
+ <meta name="flags" content="ahem" />
+
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ td { border: solid; width: 4em; background: red; padding: 0; font: 2em/1 Ahem; }
+ .bg { background: orange; color: navy; }
+ .a { margin: 0 0 1em 0; background: yellow; }
+ .c { margin: 1em 0 0 0; background: aqua; }
+ span { float: right; background: lime; padding-right: 1em; }
+ .b1 { margin: 1em 0 1em 0; }
+ .b2 { margin: 0em 0 1em 0; }
+ .b3 { margin: 1em 0 0em 0; }
+ .b4 { margin: 0em 0 0em 0; }
+ .b5 { margin: 0.5em 0 0.5em 0; }
+ .b6 { margin: 0em 0 0.5em 0; }
+ .b7 { margin: 0.5em 0 0em 0; }
+ .control .a { margin: 0 0 1em 0; }
+ .control .b { height: 0; text-align: right; }
+ .control span { float: none; }
+ .control .c { margin: 0; }
+ </style>
+ </head>
+ <body>
+ <p>All the following should look the same (and all should look like
+ the first).</p>
+ <table>
+ <tr>
+ <td class="control">
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b"><span>B</span></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b1"><span>B</span></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b2"><span>B</span></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b3"><span>B</span></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b4"><span>B</span></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b5"><span>B</span></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b6"><span>B</span></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b7"><span>B</span></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ </tr>
+ </table>
+ <p>This test is meaningless if you don't pass <a href="margin-collapse-155">test 055</a>.</p>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-155-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-155-ref.xht
new file mode 100644
index 0000000000..218c6b4f49
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-155-ref.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css"><![CDATA[
+ table {font: 50px/1 Ahem;}
+
+ td
+ {
+ background: yellow;
+ border: black solid medium;
+ color: orange;
+ padding: 1em 0;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if all 8 yellow and orange rectangles <strong>look the same</strong> (and all should look like the first rectangle).</p>
+
+
+ <table>
+ <tr>
+ <td>1</td> <td>2</td> <td>3</td> <td>4</td> <td>5</td> <td>6</td> <td>7</td> <td>8</td>
+ </tr>
+ </table>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-155.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-155.xht
new file mode 100644
index 0000000000..7f130a19af
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-155.xht
@@ -0,0 +1,93 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: effect of margins on collapsing-through</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/055.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-155-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ td { border: solid; background: red; padding: 0; font: 3.125em/1 Ahem; }
+ .bg { background: orange; color: yellow; }
+ .a { margin: 0 0 1em 0; background: lime; }
+ .c { margin: 1em 0 0 0; background: aqua; }
+ .b1 { margin: 1em 0 1em 0; }
+ .b2 { margin: 0em 0 1em 0; }
+ .b3 { margin: 1em 0 0em 0; }
+ .b4 { margin: 0em 0 0em 0; }
+ .b5 { margin: 0.5em 0 0.5em 0; }
+ .b6 { margin: 0em 0 0.5em 0; }
+ .b7 { margin: 0.5em 0 0em 0; }
+ .control .a { margin: 0 0 1em 0; }
+ .control .c { margin: 0; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if all 8 yellow and orange rectangles <strong>look the same</strong> (and all should look like the first rectangle).</p>
+ <table>
+ <tr>
+ <td class="control">
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b1"></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b2"></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b3"></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b4"></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b5"></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b6"></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ <td>
+ <div class="bg">
+ <div class="a">A</div>
+ <div class="b7"></div>
+ <div class="c">C</div>
+ </div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-156-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-156-ref.xht
new file mode 100644
index 0000000000..5e8129c4d3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-156-ref.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ table
+ {
+ border: black solid medium;
+ border-spacing: 0;
+ font-size: 50px;
+ }
+
+ td
+ {
+ background: aqua;
+ padding: 1em 0em;
+ width: 2em;
+ }
+
+ div {border-top: yellow solid 1em;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a stack of 3 horizontal bands which are <strong>from top to bottom: aqua, yellow, aqua</strong> with no red.</p>
+
+ <table>
+ <tr>
+ <td><div></div></td>
+ </tr>
+ </table>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-156.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-156.xht
new file mode 100644
index 0000000000..fc7b74c331
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-156.xht
@@ -0,0 +1,44 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (height, control) - not really margin collapsing</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/056.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-156-ref.xht" />
+
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid; background: red; }
+ td { padding: 0; width: 1em; background: red; }
+
+ .a .container { height: 1em; background: red; }
+ .a .sized { height: 3em; margin: 0; background: aqua; }
+ .a .after { height: 1em; margin: 0 0 1em 0; background: yellow; }
+
+ .b .a { border-top: solid aqua 1em; }
+ .b .b { border-top: solid yellow 1em; }
+ .b .c { border-top: solid aqua 1em; }
+
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a stack of 3 horizontal bands which are <strong>from top to bottom: aqua, yellow, aqua</strong> with no red.</p>
+ <table>
+ <tr>
+ <td class="a">
+ <div class="container">
+ <div class="sized"></div>
+ </div>
+ <div class="after"></div>
+ </td>
+ <td class="b">
+ <div class="a"></div>
+ <div class="b"></div>
+ <div class="c"></div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-159-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-159-ref.xht
new file mode 100644
index 0000000000..f9c8c4c765
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-159-ref.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ table
+ {
+ border: black solid medium;
+ border-spacing: 0;
+ font-size: 50px;
+ }
+
+ td
+ {
+ background: aqua;
+ padding: 0;
+ width: 2em;
+ }
+
+ td > p
+ {
+ background-color: yellow;
+ height: 1em;
+ margin: 1em 0em;
+ }
+
+ div {border-bottom: orange solid 1em;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a stack of 4 horizontal bands which are <strong>from top to bottom: aqua, yellow, aqua, orange</strong> with no red.</p>
+
+ <table>
+ <tr>
+ <td><p></p><div></div></td>
+ </tr>
+ </table>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-159.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-159.xht
new file mode 100644
index 0000000000..b815fcf689
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-159.xht
@@ -0,0 +1,47 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin Collapsing: in flow (height, simple) - not really margin collapsing</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/059.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="match" href="margin-collapse-159-ref.xht" />
+
+ <style type="text/css">
+ table { border-spacing: 0; font-size: 50px; border: solid; background: red; }
+ td { padding: 0; width: 1em; background: red; vertical-align: top; }
+
+ .a { background: orange; }
+ .a .container { height: 1em; background: red; }
+ .a .sized { height: 3em; margin: 0 0 1em 0; background: aqua; }
+ .a .after { height: 1em; margin: 0 0 1em 0; background: yellow; }
+
+ .b .a { border-top: solid aqua 1em; }
+ .b .b { border-top: solid yellow 1em; }
+ .b .c { border-top: solid aqua 1em; }
+ .b .d { border-top: solid orange 1em; }
+
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a stack of 4 horizontal bands which are <strong>from top to bottom: aqua, yellow, aqua, orange</strong> with no red.</p>
+ <table>
+ <tr>
+ <td class="a">
+ <div class="container">
+ <div class="sized"></div>
+ </div>
+ <div class="after"></div>
+ </td>
+ <td class="b">
+ <div class="a"></div>
+ <div class="b"></div>
+ <div class="c"></div>
+ <div class="d"></div>
+ </td>
+ </tr>
+ </table>
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-160.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-160.xht
new file mode 100644
index 0000000000..d09c81be79
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-160.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margins should not propagate into the next page</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="author" title="Elika J. Etemad" href="http://fantasai.inkedblade.net/contact"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/060.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <meta name="flags" content="paged"/>
+ <style type="text/css">
+ html { background: silver; }
+ body, body * { display: block; margin: 0; border: 0; padding: 0; }
+ .a { page-break-after: always; }
+ .c { margin: 0 0 1000em 0; }
+ .b { margin: 0; }
+ </style>
+ </head>
+ <body>
+ <div class="a">
+ <div class="c">
+ Switch to projection or print mode and switch to the second page/slide.
+ </div>
+ </div>
+ <div class="b">
+ <div>
+ This should be at the top of the second and last page.
+ </div>
+ </div>
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-162.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-162.xht
new file mode 100644
index 0000000000..6aa2c8b5bd
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-162.xht
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin collapsing with floats before self collapsing children with margins collapsing with parent</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/062.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ /* This test requires half-decent z-index support */
+ /* Rendering should not not match 061.html! */
+ html { margin: 0; padding: 0; }
+ body { margin: 0 10px; padding: 0; }
+ .a { position: absolute; top: 46px; left: 10px; width: 20em; height: 4em; background: red; color: yellow; z-index: -1; }
+ .b { float: left; width: 20em; height: 4em; background: green; color: white; }
+ .c1 { margin: 2px; }
+ .c2 { margin: -4px 20px; }
+ .c3 { margin: 0 0 14px; }
+ .c4 { margin: 50px; }
+ </style>
+ </head>
+ <body>
+ <div class="c1">
+ <div class="c2">
+ <div class="c3"></div>
+ </div>
+ </div>
+ <div class="a">FAIL</div>
+ <div class="b">This block should be green.</div>
+ <div class="c4"></div>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-163.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-163.xht
new file mode 100644
index 0000000000..eaaa743a12
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-163.xht
@@ -0,0 +1,32 @@
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <title>CSS Test: Margin collapsing with floats before self collapsing children with margins not collapsing with parent</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/063.html" type="text/html"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ /* This test requires half-decent z-index support */
+ html { margin: 0; padding: 0; }
+ body { margin: 0 10px; padding: 0; }
+ .a { position: absolute; top: 13px; left: 10px; width: 20em; height: 4em; background: red; color: yellow; z-index: -1; }
+ .b { float: left; width: 20em; height: 4em; background: green; color: white; }
+ .c1 { margin: 2px; padding-top: 1px; } /* prevent collapsing with parent */
+ .c2 { margin: -4px 20px; }
+ .c3 { margin: 0 0 14px; }
+ .c4 { margin: 50px; }
+ </style>
+ </head>
+ <body>
+ <div class="c1">
+ <div class="c2">
+ <div class="c3"></div>
+ </div>
+ </div>
+ <div class="a">FAIL</div>
+ <div class="b">This block should be green.</div>
+ <div class="c4"></div>
+
+
+</body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-000.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-000.xht
new file mode 100644
index 0000000000..348444a784
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-000.xht
@@ -0,0 +1,32 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin Collapsing with Clearance</title>
+ <link rel="author" title="Microsoft" href="http://microsoft.com/"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#flow-control"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ div.target1 { position: absolute; left: -15px; height: 50px; width: 0; border-left: 10px solid yellow; top: 0px; }
+ div.target3 { position: absolute; left: -15px; height: 50px; width: 0; border-left: 5px solid orange; top: 100px; }
+ div.target4 { position: absolute; left: -10px; height: 50px; width: 0; border-left: 5px solid silver; top: 100px; }
+ div.container { width: 150px; position: relative; margin-left: 20px; border: solid thin; }
+ div.box1 { height: 50px; margin: 0; background-color: yellow; }
+ div.parentof2and3 { margin: 0; background-color: silver; padding-right: 10px; }
+ div.box2 { display: none; }
+ div.box3 { margin-top: 50px; height: 50px; background-color: orange; }
+ </style>
+ </head>
+ <body>
+ <p>The coloured bars on the left should match the coloured boxes in the black box.</p>
+ <div class="container">
+ <div class="target1"></div>
+ <div class="target3"></div>
+ <div class="target4"></div>
+ <div class="box1">A</div>
+ <div class="parentof2and3">
+ <div class="box2">B</div>
+ <div class="box3">C</div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-001.xht
new file mode 100644
index 0000000000..64bb404982
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-001.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin Collapsing with Clearance</title>
+ <link rel="author" title="Microsoft" href="http://microsoft.com/"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#flow-control"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ div.target1 { position: absolute; left: -15px; height: 50px; width: 0; border-left: 10px solid yellow; top: 0px; }
+ div.target2 { position: absolute; left: -15px; height: 20px; width: 0; border-left: 5px solid aqua; top: 50px; }
+ div.target3 { position: absolute; left: -15px; height: 50px; width: 0; border-left: 10px solid orange; top: 100px; }
+ div.container { width: 150px; position: relative; margin-left: 20px; border: solid thin; }
+ div.box1 { height: 50px; background-color: yellow; }
+ div.box2 { background-color: aqua; float: left; width: 20px; height: 20px; }
+ div.box3 { margin-top: 50px; height: 50px; background-color: orange; }
+ </style>
+ </head>
+ <body>
+ <p>The coloured bars on the left should match the coloured boxes in the black box.</p>
+ <div class="container">
+ <div class="target1"></div>
+ <div class="target2"></div>
+ <div class="target3"></div>
+ <div class="box1">A</div>
+ <div class="box2">B</div>
+ <div class="box3">C</div>
+ </div>
+ </body>
+</html>
+
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-004.xht
new file mode 100644
index 0000000000..5be63f6100
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-004.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin Collapsing with Clearance</title>
+ <link rel="author" title="Microsoft" href="http://microsoft.com/"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#flow-control"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <style type="text/css">
+ div.target1 { position: absolute; left: -20px; height: 50px; width: 0; border-left: 15px solid yellow; top: 0px; }
+ div.target2 { position: absolute; left: -20px; height: 20px; width: 0; border-left: 5px solid aqua; border-right: 5px solid orange; top: 100px; }
+ div.target3 { position: absolute; left: -20px; height: 30px; width: 0; border-left: 10px solid orange; top: 120px; }
+ div.target4 { position: absolute; left: -10px; height: 50px; width: 0; border-left: 5px solid silver; top: 100px; }
+ div.container { width: 150px; position: relative; margin-left: 20px; border: solid thin; }
+ div.box1 { height: 50px; background-color: yellow; }
+ div.parentof2and3 { background-color: silver; padding-right: 10px; }
+ div.box2 { background-color: aqua; float: left; width: 20px; height: 20px; }
+ div.box3 { margin-top: 50px; height: 50px; background-color: orange; }
+ </style>
+ </head>
+ <body>
+ <p>The coloured bars on the left should match the coloured boxes in the black box.</p>
+ <div class="container">
+ <div class="target1"></div>
+ <div class="target2"></div>
+ <div class="target3"></div>
+ <div class="target4"></div>
+ <div class="box1">A</div>
+ <div class="parentof2and3">
+ <div class="box2">B</div>
+ <div class="box3">C</div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-006.xht
new file mode 100644
index 0000000000..f8e2561ffb
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-006.xht
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin Collapsing with Clearance</title>
+ <link rel="author" title="Microsoft" href="http://microsoft.com/"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#flow-control"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#floats"/>
+ <style type="text/css">
+ div.target1 { position: absolute; left: -15px; height: 50px; width: 0; border-left: 10px solid yellow; top: 0px; }
+ div.target3 { position: absolute; left: -15px; height: 50px; width: 0; border-left: 5px solid orange; top: 100px; }
+ div.target4 { position: absolute; left: -10px; height: 50px; width: 0; border-left: 5px solid silver; top: 100px; }
+ div.container { width: 150px; position: relative; margin-left: 20px; border: solid thin; }
+ div.box1 { height: 50px; margin: 0; background-color: yellow; }
+ div.parentof2and3 { margin: 0; background-color: silver; padding-right: 10px; }
+ div.box2 { display: none; }
+ div.box3 { overflow: hidden; margin-top: 50px; height: 50px; background-color: orange; }
+ </style>
+ </head>
+ <body>
+ <p>The coloured bars on the left should match the coloured boxes in the black box.</p>
+ <div class="container">
+ <div class="target1"></div>
+ <div class="target3"></div>
+ <div class="target4"></div>
+ <div class="box1">A</div>
+ <div class="parentof2and3">
+ <div class="box2">B</div>
+ <div class="box3">C</div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-007.xht
new file mode 100644
index 0000000000..4c320ac187
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-007.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin Collapsing with Clearance</title>
+ <link rel="author" title="Microsoft" href="http://microsoft.com/"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#flow-control"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#floats"/>
+ <style type="text/css">
+ div.target1 { position: absolute; left: -15px; height: 50px; width: 0; border-left: 10px solid yellow; top: 0px; }
+ div.target2 { position: absolute; left: -15px; height: 20px; width: 0; border-left: 5px solid aqua; top: 50px; }
+ div.target3 { position: absolute; left: -15px; height: 50px; width: 0; border-left: 10px solid orange; top: 100px; }
+ div.container { width: 150px; position: relative; margin-left: 20px; border: solid thin; }
+ div.box1 { height: 50px; background-color: yellow; }
+ div.box2 { background-color: aqua; float: left; width: 20px; height: 20px; }
+ div.box3 { overflow: hidden; margin-top: 50px; height: 50px; background-color: orange; }
+ </style>
+ </head>
+ <body>
+ <p>The coloured bars on the left should match the coloured boxes in the black box.</p>
+ <div class="container">
+ <div class="target1"></div>
+ <div class="target2"></div>
+ <div class="target3"></div>
+ <div class="box1">A</div>
+ <div class="box2">B</div>
+ <div class="box3">C</div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-010.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-010.xht
new file mode 100644
index 0000000000..19cc99be49
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-clear-010.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin Collapsing with Clearance</title>
+ <link rel="author" title="Microsoft" href="http://microsoft.com/"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#flow-control"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#floats"/>
+ <style type="text/css">
+ div.target1 { position: absolute; left: -20px; height: 50px; width: 0; border-left: 15px solid yellow; top: 0px; }
+ div.target2 { position: absolute; left: -20px; height: 20px; width: 0; border-left: 5px solid aqua; top: 100px; }
+ div.target3 { position: absolute; left: -20px; height: 30px; width: 0; border-left: 5px solid silver; top: 120px; }
+ div.target4 { position: absolute; left: -15px; height: 50px; width: 0; border-left: 5px solid orange; top: 100px; }
+ div.target5 { position: absolute; left: -10px; height: 50px; width: 0; border-left: 5px solid silver; top: 100px; }
+ div.container { width: 150px; position: relative; margin-left: 20px; border: solid thin; }
+ div.box1 { height: 50px; background-color: yellow; }
+ div.parentof2and3 { background-color: silver; padding-right: 10px; }
+ div.box2 { background-color: aqua; float: left; width: 20px; height: 20px; }
+ div.box3 { overflow: hidden; margin-top: 50px; height: 50px; background-color: orange; }
+ </style>
+ </head>
+ <body>
+ <p>The coloured bars on the left should match the coloured boxes in the black box.</p>
+ <div class="container">
+ <div class="target1"></div>
+ <div class="target2"></div>
+ <div class="target3"></div>
+ <div class="target4"></div>
+ <div class="target5"></div>
+ <div class="box1">A</div>
+ <div class="parentof2and3">
+ <div class="box2">B</div>
+ <div class="box3">C</div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-001-ref.xht
new file mode 100644
index 0000000000..f86d2b201f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-001-ref.xht
@@ -0,0 +1,17 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>CSS Reference File</title>
+<link rel="author" title="Bert Bos" href="mailto:bert@w3.org" />
+<style type="text/css">
+ body {min-width: 17em}
+ div.parent {height: 2em; margin: 5em 0 1em 0}
+</style>
+</head>
+ <body>
+ <div class="parent">
+ There's more space above this line than between this line and the horizontal rule
+ </div>
+ <hr />
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-001.xht
new file mode 100644
index 0000000000..2c69362443
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-001.xht
@@ -0,0 +1,27 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>CSS margin: Margin collapsing and elements with min-height</title>
+<link rel="author" title="Bert Bos" href="mailto:bert@w3.org" />
+<link rel="help" href="http://www.w3.org/TR/CSS22/box.html#collapsing-margins" />
+<link rel="help" href="http://www.w3.org/TR/CSS22/changes.html#s.8.3.1c" />
+<link rel="match" href="margin-collapse-min-height-001-ref.xht" />
+<meta name="assert" content="If the top margin of a box with non-zero computed 'min-height' and 'auto' computed 'height' collapses with the bottom margin of its last in-flow child, then the child's bottom margin does not collapse with the parent's bottom margin." />
+<style type="text/css">
+ body {min-width: 17em}
+ div.parent {min-height: 2em; height: auto; margin: 1em 0}
+ div.last-child {margin-bottom: 5em}
+ div.float {float: left}
+</style>
+</head>
+ <body>
+ <div class="parent">
+ <div></div>
+ <div></div>
+ <div class="last-child">
+ <div class="float">There's more space above this line than between this line and the horizontal rule</div>
+ </div>
+ </div>
+ <hr />
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-002-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-002-ref.xht
new file mode 100644
index 0000000000..84963fd2b9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-002-ref.xht
@@ -0,0 +1,22 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>CSS margin: Margin collapsing and elements with min-height</title>
+<link rel="author" title="Bert Bos" href="mailto:bert@w3.org" />
+<style type="text/css">
+ #container {width: 50px; border-top: 1px solid transparent;
+ background: green}
+ #parent {height: 50px; background-color: white; margin-top: 50px}
+ #following-sibling {height: 50px; background-color: green}
+</style>
+</head>
+ <body>
+ <p>There should be two solid green squares and no red on this page</p>
+
+ <div id="container" >
+ <div id="parent">
+ </div>
+ <div id="following-sibling"></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-002.xht
new file mode 100644
index 0000000000..240fc177fd
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-collapse-min-height-002.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>CSS margin: Margin collapsing and elements with min-height</title>
+<link rel="author" title="Bert Bos" href="mailto:bert@w3.org" />
+<link rel="help" href="http://www.w3.org/TR/CSS22/box.html#collapsing-margins" />
+<link rel="help" href="http://www.w3.org/TR/CSS22/changes.html#s.8.3.1c" />
+<link rel="match" href="margin-collapse-min-height-002-ref.xht" />
+<meta name="assert" content="If the top margin of a box with non-zero computed 'min-height' and 'auto' computed 'height' collapses with the bottom margin of its last in-flow child, then the child's bottom margin does not collapse with the parent's bottom margin." />
+<style type="text/css">
+ #container {width: 50px; height: 50px; border-top: 1px solid transparent;
+ border-bottom: 100px solid red; background: green}
+ #parent {height: auto; min-height: 50px; background-color: white}
+ #child {margin-bottom: 50px}
+ #following-sibling {height: 50px; background-color: green}
+</style>
+</head>
+ <body>
+ <!-- Credit for this test goes to Anton Prowse, see
+ https://www.w3.org/Bugs/Public/show_bug.cgi?id=16036#c4 -->
+ <p>There should be two solid green squares and no red on this page</p>
+ <div id="container" >
+ <div id="parent">
+ <div id="child"></div>
+ </div>
+ <div id="following-sibling"></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-em-inherit-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-em-inherit-001-ref.xht
new file mode 100644
index 0000000000..8d2a87b7ad
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-em-inherit-001-ref.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p
+ {
+ font: 1em/1.25 serif;
+ margin: 1em 0em;
+ }
+
+ div
+ {
+ background-color: green;
+ height: 194px;
+ left: 118px;
+ position: relative;
+ top: 46px;
+ width: 392px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green<br />
+ rectangle and if there is no red.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-em-inherit-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-em-inherit-001.xht
new file mode 100644
index 0000000000..57af6a5701
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-em-inherit-001.xht
@@ -0,0 +1,97 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Test: inherit applied on margin set with em</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+ <link rel="help" title="4.3.2 Length" href="http://www.w3.org/TR/CSS21/syndata.html#length-units" />
+ <link rel="help" title="6.2.1 The 'inherit' value" href="http://www.w3.org/TR/CSS21/cascade.html#value-def-inherit" />
+ <link rel="help" href="http://www.w3.org/TR/css-cascade-3/#inherit" />
+ <link rel="help" href="http://www.w3.org/TR/css-cascade-4/#inherit" />
+ <link rel="help" title="8.3 Margin properties" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-em-inherit-001-ref.xht" />
+
+ <meta content="The 'em' unit is equal to the computed value of the 'font-size' property of the element on which it is used. When inherit keyword is used, the property takes the same computed value - a length value in this testcase - as the property for the element's parent." name="assert" />
+ <meta content="image" name="flags" />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p
+ {
+ font: 1em/1.25 serif;
+ margin: 1em 0em;
+ }
+
+ div#grand-parent {width: 600px;}
+
+ div#parent
+ {
+ background-color: green;
+ border: white solid 6px;
+ /*
+ Such border prevents margin collapsing between
+ #parent's vertical margins and #child's vertical margins
+ */
+ font-size: 28px;
+ margin: 2em 3em 1em 4em; /* 56px 84px 28px 112px */
+ }
+
+ div#child
+ {
+ font-size: 40px;
+ margin: inherit;
+ /*
+ What is inherited is a computed length value: so
+ it is 56px 84px 28px 112px and not 80px 120px 40px 160px
+ */
+ }
+
+ div#abs-pos-overlapping-green
+ {
+ left: 238px;
+ position: absolute;
+ top: 174px;
+ }
+
+ /*
+ 8px (body's margin-left)
+ + 112px (#parent's margin-left)
+ + 6px (#parent's border-left)
+ + 112px (#child's margin-left)
+ ==================
+ 238px
+ */
+
+ /*
+ 16px (max(8px, 16px): body's margin-top collapses with p's margin-top)
+ + 20px (first line)
+ + 20px (second line)
+ + 56px (max(16px, 56px): p's margin-bottom collapses with #parent's margin-top)
+ + 6px (#parent's border-top)
+ + 56px (#child's margin-top)
+ ==================
+ 174px
+ */
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green<br />
+ rectangle and if there is no red.</p>
+
+ <div id="grand-parent">
+ <div id="parent">
+ <div id="child"><img src="support/100x100-red.png" alt="Image download support must be enabled" /></div>
+ </div>
+ </div>
+
+ <div id="abs-pos-overlapping-green"><img src="support/swatch-green.png" width="100" height="100" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-001-ref.xht
new file mode 100644
index 0000000000..2d5c60f84c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-001-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: green;
+ border: green solid 3px;
+ height: 60px;
+ width: 80px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a small filled green rectangle and <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-001.xht
new file mode 100644
index 0000000000..d94030b53c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-001.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin on non-replaced inline elements</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-inline-001-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="Non-replaced inline elements do not apply vertical margins." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ background: red;
+ border: solid green 3px;
+ font-family: Ahem;
+ font-size: 1.25em;
+ line-height: 1;
+ width: 4em;
+ }
+ span
+ {
+ background: green;
+ color: green;
+ margin: 2em 0;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a small filled green rectangle and <strong>no red</strong>.</p>
+ <div>
+ <span>XXXX XXXX XXXX</span>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-002-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-002-ref.xht
new file mode 100644
index 0000000000..4974ac64b8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-002-ref.xht
@@ -0,0 +1,26 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border: blue solid 3px;}
+
+ span {background-color: orange;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if the top and bottom of the orange stripe is touching the inner edges of the hollow blue rectangle.</p>
+
+ <div><span>Filler Text</span></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-002.xht
new file mode 100644
index 0000000000..ac2011f90e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-inline-002.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top and margin-bottom on inline elements</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-inline-002-ref.xht" />
+
+ <meta name="assert" content="Applying margin-top and margin-bottom to an inline element has no effect." />
+ <style type="text/css">
+ div
+ {
+ border: blue solid 3px;
+ }
+ span
+ {
+ background: orange;
+ margin-top: 20px;
+ margin-bottom: 20px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if the top and bottom of the orange stripe is touching the inner edges of the hollow blue rectangle.</p>
+ <div>
+ <span>Filler Text</span>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-004-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-004-ref.xht
new file mode 100644
index 0000000000..8cacc367e9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-004-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: blue;
+ border-right: orange solid 5px;
+ height: 96px;
+ width: 5px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-004.xht
new file mode 100644
index 0000000000..999fbf0f18
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-004.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using pixels with a negative zero value, -0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a negative zero length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: -0px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-005.xht
new file mode 100644
index 0000000000..2ad62434b8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-005.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using pixels with a zero value, 0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a zero length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: 0px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-006.xht
new file mode 100644
index 0000000000..7dba8bb9ee
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-006.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using pixels with a positive zero value, +0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a positive zero length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: +0px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-007-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-007-ref.xht
new file mode 100644
index 0000000000..6156f74fc5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-007-ref.xht
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 2px;
+ height: 1in;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-007.xht
new file mode 100644
index 0000000000..af33f6e9fd
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-007.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using pixels with a nominal value, 96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-007-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 2px solid red;
+ }
+ #div1
+ {
+ margin-left: 96px;
+ }
+ #div2
+ {
+ border-left: 2px solid black;
+ margin-left: -98px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-008.xht
new file mode 100644
index 0000000000..9f36cd8d16
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-008.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using pixels with a nominal value with a plus sign, +96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-007-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in pixels with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 2px solid red;
+ }
+ #div1
+ {
+ margin-left: +96px;
+ }
+ #div2
+ {
+ border-left: 2px solid black;
+ margin-left: -98px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-016.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-016.xht
new file mode 100644
index 0000000000..6355c880ba
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-016.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using points with a negative zero value, -0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a negative zero length value in points." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: -0pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-017.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-017.xht
new file mode 100644
index 0000000000..ba2928a70e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-017.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using points with a zero value, 0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a zero length value in points." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: 0pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-018.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-018.xht
new file mode 100644
index 0000000000..c5451d1442
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-018.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using points with a positive zero value, +0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a positive zero length value in points." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: +0pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-019-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-019-ref.xht
new file mode 100644
index 0000000000..fea54e218f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-019-ref.xht
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 8px;
+ height: 1in;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-019.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-019.xht
new file mode 100644
index 0000000000..201a653fbe
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-019.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using points with a nominal value, 72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-019-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in points." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 6pt solid red;
+ }
+ #div1
+ {
+ margin-left: 72pt;
+ }
+ #div2
+ {
+ border-left: 6pt solid black;
+ margin-left: -78pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-020.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-020.xht
new file mode 100644
index 0000000000..69fca4a3e1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-020.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using points with a nominal value with a plus sign, +72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-019-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in points with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 6pt solid red;
+ }
+ #div1
+ {
+ margin-left: +72pt;
+ }
+ #div2
+ {
+ border-left: 6pt solid black;
+ margin-left: -78pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-028.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-028.xht
new file mode 100644
index 0000000000..4f522a787b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-028.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using picas with a negative zero value, -0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a negative zero length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: -0pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-029.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-029.xht
new file mode 100644
index 0000000000..99f9c1bba5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-029.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using picas with a zero value, 0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a zero length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: 0pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-030.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-030.xht
new file mode 100644
index 0000000000..54ba6e53e9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-030.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using picas with a positive zero value, +0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a positive zero length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: +0pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-031-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-031-ref.xht
new file mode 100644
index 0000000000..b6193f2afe
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-031-ref.xht
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 16px;
+ height: 1in;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-031.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-031.xht
new file mode 100644
index 0000000000..f5143c2802
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-031.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using picas with a nominal value, 6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-031-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 1pc solid red;
+ }
+ #div1
+ {
+ margin-left: 6pc;
+ }
+ #div2
+ {
+ border-left: 1pc solid black;
+ margin-left: -7pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-032.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-032.xht
new file mode 100644
index 0000000000..7a2f3594c3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-032.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using picas with a nominal value with a plus sign, +6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-031-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in picas with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 1pc solid red;
+ }
+ #div1
+ {
+ margin-left: +6pc;
+ }
+ #div2
+ {
+ border-left: 1pc solid black;
+ margin-left: -7pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-040.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-040.xht
new file mode 100644
index 0000000000..74154a4f42
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-040.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using centimeters with a negative zero value, -0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a negative zero length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: -0cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-041.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-041.xht
new file mode 100644
index 0000000000..df40cd6eae
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-041.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using centimeters with a zero value, 0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a zero length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: 0cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-042.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-042.xht
new file mode 100644
index 0000000000..d388610933
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-042.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using centimeters with a positive zero value, +0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a positive zero length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: +0cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-043-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-043-ref.xht
new file mode 100644
index 0000000000..cbdc8253fb
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-043-ref.xht
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 96px;
+ height: 1in;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-043.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-043.xht
new file mode 100644
index 0000000000..309633873e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-043.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using centimeters with a nominal value, 2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 2.54cm solid red;
+ }
+ #div1
+ {
+ margin-left: 2.54cm;
+ }
+ #div2
+ {
+ border-left: 2.54cm solid black;
+ margin-left: -5.08cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-044.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-044.xht
new file mode 100644
index 0000000000..cef150cb43
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-044.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using centimeters with a nominal value with a plus sign, +2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in centimeters with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 2.54cm solid red;
+ }
+ #div1
+ {
+ margin-left: +2.54cm;
+ }
+ #div2
+ {
+ border-left: 2.54cm solid black;
+ margin-left: -5.08cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-052.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-052.xht
new file mode 100644
index 0000000000..72c5f92080
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-052.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using millimeters with a negative zero value, -0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a negative zero length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: -0mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-053.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-053.xht
new file mode 100644
index 0000000000..f93f4987e2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-053.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using millimeters with a zero value, 0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a zero length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: 0mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-054.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-054.xht
new file mode 100644
index 0000000000..758d1c696f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-054.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using millimeters with a positive zero value, +0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a positive zero length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: +0mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-055.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-055.xht
new file mode 100644
index 0000000000..089eb4da51
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-055.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using millimeters with a nominal value, 25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 25.4mm solid red;
+ }
+ #div1
+ {
+ margin-left: 25.4mm;
+ }
+ #div2
+ {
+ border-left: 25.4mm solid black;
+ margin-left: -50.8mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-056.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-056.xht
new file mode 100644
index 0000000000..4cecfcf8e6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-056.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using millimeters with a nominal value with a plus sign, +25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in millimeters with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 25.4mm solid red;
+ }
+ #div1
+ {
+ margin-left: +25.4mm;
+ }
+ #div2
+ {
+ border-left: 25.4mm solid black;
+ margin-left: -50.8mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-064.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-064.xht
new file mode 100644
index 0000000000..8ab39558de
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-064.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using inches with a negative zero value, -0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a negative zero length value in inches." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: -0in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-065.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-065.xht
new file mode 100644
index 0000000000..40891d6221
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-065.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using inches with a zero value, 0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a zero length value in inches." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: 0in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-066.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-066.xht
new file mode 100644
index 0000000000..eea1b43ef1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-066.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using inches with a positive zero value, +0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a positive zero length value in inches." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: +0in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-067-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-067-ref.xht
new file mode 100644
index 0000000000..9771afc090
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-067-ref.xht
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 24px;
+ height: 1in;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-067.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-067.xht
new file mode 100644
index 0000000000..45a9985f73
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-067.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using inches with a nominal value, 1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-067-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in inches." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 0.25in solid red;
+ }
+ #div1
+ {
+ margin-left: 1in;
+ }
+ #div2
+ {
+ border-left: 0.25in solid black;
+ margin-left: -1.25in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-068.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-068.xht
new file mode 100644
index 0000000000..7cd11b9293
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-068.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using inches with a nominal value with a plus sign, +1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-067-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in inches with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 0.25in solid red;
+ }
+ #div1
+ {
+ margin-left: +1in;
+ }
+ #div2
+ {
+ border-left: 0.25in solid black;
+ margin-left: -1.25in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-076.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-076.xht
new file mode 100644
index 0000000000..04fef47a02
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-076.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using 'em' units with a negative zero value, -0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-left' property sets a negative zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: -0em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-077.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-077.xht
new file mode 100644
index 0000000000..5a11aa7923
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-077.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using 'em' units with a zero value, 0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-left' property sets a zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: 0em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-078.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-078.xht
new file mode 100644
index 0000000000..38786d4fdc
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-078.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using 'em' units with a positive zero value, +0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-left' property sets a positive zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: +0em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-079-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-079-ref.xht
new file mode 100644
index 0000000000..a3575bf249
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-079-ref.xht
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 20px;
+ height: 1in;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-079.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-079.xht
new file mode 100644
index 0000000000..fbbbfd2ab4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-079.xht
@@ -0,0 +1,44 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using 'em' units with a nominal value, 6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+
+ }
+ #wrapper
+ {
+ border-left: 1em solid red;
+ }
+ #div1
+ {
+ margin-left: 6em;
+ }
+ #div2
+ {
+ border-left: 1em solid black;
+ margin-left: -7em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-080.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-080.xht
new file mode 100644
index 0000000000..0f5db5898a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-080.xht
@@ -0,0 +1,43 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using 'em' units with a nominal value with a plus sign, +6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in 'em' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 1em solid red;
+ }
+ #div1
+ {
+ margin-left: +6em;
+ }
+ #div2
+ {
+ border-left: 1em solid black;
+ margin-left: -7em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-088.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-088.xht
new file mode 100644
index 0000000000..af934ac1e4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-088.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using 'ex' units with a negative zero value, -0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-left' property sets a negative zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: -0ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-089.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-089.xht
new file mode 100644
index 0000000000..0092455418
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-089.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using 'ex' units with a zero value, 0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-left' property sets a zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: 0ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-090.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-090.xht
new file mode 100644
index 0000000000..bd946f2bb6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-090.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using 'ex' units with a positive zero value, +0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-left' property sets a positive zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: +0ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-091.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-091.xht
new file mode 100644
index 0000000000..ae73c469df
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-091.xht
@@ -0,0 +1,43 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using 'ex' units with a nominal value, 7.5ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 1ex solid red;
+ }
+ #div1
+ {
+ margin-left: 7.5ex;
+ }
+ #div2
+ {
+ border-left: 1ex solid black;
+ margin-left: -8.5ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-092.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-092.xht
new file mode 100644
index 0000000000..ec22c20376
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-092.xht
@@ -0,0 +1,43 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using 'ex' units with a nominal value with a plus sign, +7.5ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in 'ex' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 1ex solid red;
+ }
+ #div1
+ {
+ margin-left: +7.5ex;
+ }
+ #div2
+ {
+ border-left: 1ex solid black;
+ margin-left: -8.5ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-100.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-100.xht
new file mode 100644
index 0000000000..da10f7d570
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-100.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using percentages with a negative zero value, -0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a negative zero length value in percentages." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ width: 1in;
+ }
+ #wrapper
+ {
+ border-left: 5px solid blue;
+ }
+ #div1
+ {
+ margin-left: -0%;
+ }
+ #div2
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-101.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-101.xht
new file mode 100644
index 0000000000..80796b1b63
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-101.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using percentages with a zero value, 0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a zero length value in percentages." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ width: 1in;
+ }
+ #wrapper
+ {
+ border-left: 5px solid blue;
+ }
+ #div1
+ {
+ margin-left: 0%;
+ }
+ #div2
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-102.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-102.xht
new file mode 100644
index 0000000000..2d287296bb
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-102.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using percentages with a positive zero value, +0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a positive zero length value in percentages." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ width: 1in;
+ }
+ #wrapper
+ {
+ border-left: 5px solid blue;
+ }
+ #div1
+ {
+ margin-left: +0%;
+ }
+ #div2
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-103-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-103-ref.xht
new file mode 100644
index 0000000000..287aab32b5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-103-ref.xht
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 48px;
+ height: 1in;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-103.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-103.xht
new file mode 100644
index 0000000000..74907db885
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-103.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using percentages with a nominal value, 50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-103-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in percentages." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 0.5in solid red;
+ width: 1in;
+ }
+ #div1
+ {
+ margin-left: 50%;
+ }
+ #div2
+ {
+ border-left: 0.5in solid black;
+ margin-left: -1in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-104.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-104.xht
new file mode 100644
index 0000000000..5d5e3cfb58
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-104.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left using percentages with a nominal value with a plus sign, +50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-103-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a nominal length value in percentages with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-left: 0.5in solid red;
+ width: 1in;
+ }
+ #div1
+ {
+ margin-left: +50%;
+ }
+ #div2
+ {
+ border-left: 0.5in solid black;
+ margin-left: -1in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-109.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-109.xht
new file mode 100644
index 0000000000..7ed4d7b539
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-109.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left sets a negative zero value with no units, -0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a negative zero length value with no units." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: -0;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-110.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-110.xht
new file mode 100644
index 0000000000..512152b00e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-110.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left sets a zero value with no units, 0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a zero length value with no units." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: 0;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-111.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-111.xht
new file mode 100644
index 0000000000..1b5f74a390
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-111.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left sets a positive zero value with no units, +0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a positive zero length value with no units." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: +0;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-112.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-112.xht
new file mode 100644
index 0000000000..2710cfee3d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-112.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left with a value of 'auto'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a value of 'auto'." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: auto;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-113-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-113-ref.xht
new file mode 100644
index 0000000000..b1dffbed1c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-113-ref.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 3px;
+ height: 1in;
+ left: 96px;
+ position: relative;
+ width: 400px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-113.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-113.xht
new file mode 100644
index 0000000000..547d330e8e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-113.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left with a value of 'inherit'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-113-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property sets a value of 'inherit'." />
+ <style type="text/css">
+ #wrapper
+ {
+ margin-left: 1in;
+ }
+ div
+ {
+ height: 1in;
+ position: relative;
+ width: 1in;
+ }
+ #div1
+ {
+ border-left: 3px solid red;
+ left: 0;
+ position: absolute;
+ }
+ #div2
+ {
+ margin-left: inherit;
+ }
+ #div3
+ {
+ border-left: 3px solid black;
+ margin-left: -1in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2">
+ <div id="div3"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-001-ref.xht
new file mode 100644
index 0000000000..06591fc3db
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-001-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: blue;
+ border-right: orange solid 10px;
+ height: 200px;
+ width: 10px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-001.xht
new file mode 100644
index 0000000000..aad086e328
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-001.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left applied to element with display table-row-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property does not apply to elements with a display of table-row-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #test
+ {
+ display: table-row-group;
+ margin-left: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-left: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-002.xht
new file mode 100644
index 0000000000..aae6789a58
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-002.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left applied to element with display table-header-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property does not apply to elements with a display of table-header-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #test
+ {
+ display: table-header-group;
+ margin-left: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-left: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-003.xht
new file mode 100644
index 0000000000..f6a32e1af9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-003.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left applied to element with display table-footer-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property does not apply to elements with a display of table-footer-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #test
+ {
+ display: table-footer-group;
+ margin-left: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-left: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-004.xht
new file mode 100644
index 0000000000..0ba2c8cae5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-004.xht
@@ -0,0 +1,44 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left applied to element with display table-row</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property does not apply to elements with a display of table-row." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ margin-left: 50px;
+ }
+ #cell
+ {
+ border-left: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-005.xht
new file mode 100644
index 0000000000..b766cfb148
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-005.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left applied to element with display table-column-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property does not apply to elements with a display of table-column-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #test
+ {
+ display: table-column-group;
+ margin-left: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-left: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-006.xht
new file mode 100644
index 0000000000..12fcb9f2f3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-006.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left applied to element with display table-column</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property does not apply to elements with a display of table-column." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #test
+ {
+ display: table-column;
+ margin-left: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-left: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-007.xht
new file mode 100644
index 0000000000..061c78edd6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-007.xht
@@ -0,0 +1,44 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left applied to element with display table-cell</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property does not apply to elements with a display of table-cell." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-left: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ margin-left: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-008.xht
new file mode 100644
index 0000000000..2121019ae8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-008.xht
@@ -0,0 +1,32 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left applied to element with display inline</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <meta name="assert" content="The 'margin-left' property applies to elements with a display of inline." />
+ <style type="text/css">
+ div
+ {
+ display: inline;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ margin-left: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="div1">
+ <div>Filler Text</div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-009-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-009-ref.xht
new file mode 100644
index 0000000000..ea693efa74
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-009-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: blue solid 10px;
+ border-right: orange solid 10px;
+ height: 200px;
+ width: 50px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is space between the blue and orange lines.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-009.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-009.xht
new file mode 100644
index 0000000000..7301e5bd68
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-009.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left applied to element with display block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property applies to elements with a display of block." />
+ <style type="text/css">
+ div, span
+ {
+ height: 200px;
+ }
+ div
+ {
+ border-left: 10px solid blue;
+ }
+ span
+ {
+ border-left: 10px solid orange;
+ display: block;
+ margin-left: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div>
+ <span></span>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-010.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-010.xht
new file mode 100644
index 0000000000..beea15e4d4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-010.xht
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left applied to element with display list-item</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <meta name="assert" content="The 'margin-left' property applies to elements with a display of list-item." />
+ <style type="text/css">
+ div
+ {
+ height: 200px;
+ }
+ #div1
+ {
+ border-left: 10px solid blue;
+ }
+ div div
+ {
+ border-left: 10px solid orange;
+ display: list-item;
+ margin-left: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines and there is a marker bullet between the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-012.xht
new file mode 100644
index 0000000000..8e7fc4648c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-012.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left applied to element with display inline-block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property applies to elements with a display of inline-block." />
+ <style type="text/css">
+ div
+ {
+ height: 200px;
+ }
+ #div1
+ {
+ border-left: 10px solid blue;
+ }
+ div div
+ {
+ border-left: 10px solid orange;
+ display: inline-block;
+ margin-left: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-013.xht
new file mode 100644
index 0000000000..1c18442c99
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-013.xht
@@ -0,0 +1,44 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left applied to element with display table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property applies to elements with a display of table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #table
+ {
+ border-left: 10px solid orange;
+ display: table;
+ margin-left: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-014.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-014.xht
new file mode 100644
index 0000000000..431b81e93d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-014.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left applied to element with display inline-table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property applies to elements with a display of inline-table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #table
+ {
+ border-left: 10px solid orange;
+ display: inline-table;
+ margin-left: 50px;
+ vertical-align: top;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-015.xht
new file mode 100644
index 0000000000..3b2f998923
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-left-applies-to-015.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-left applied to element with display table-caption</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-17 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-left' property applies to elements with a display of table-caption." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #test
+ {
+ border-left: 10px solid orange;
+ display: table-caption;
+ height: 200px;
+ margin-left: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-percentage-inherit-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-percentage-inherit-001-ref.xht
new file mode 100644
index 0000000000..bab16ed1df
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-percentage-inherit-001-ref.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p
+ {
+ font: 1em/1.25 serif;
+ margin: 1em 0em;
+ }
+
+ div
+ {
+ background-color: green;
+ height: 164px;
+ left: 63px;
+ position: relative;
+ top: 47px;
+ width: 200px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green<br />
+ rectangle and if there is no red.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-percentage-inherit-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-percentage-inherit-001.xht
new file mode 100644
index 0000000000..5e73777157
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-percentage-inherit-001.xht
@@ -0,0 +1,95 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Test: margin - inherit applied on margin percentage</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+ <link rel="help" title="8.3 Margin properties" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="help" title="6.2.1 The 'inherit' value" href="http://www.w3.org/TR/CSS21/cascade.html#value-def-inherit" />
+ <link rel="help" href="http://www.w3.org/TR/css-cascade-3/#inherit" />
+ <link rel="help" href="http://www.w3.org/TR/css-cascade-4/#inherit" />
+ <link rel="match" href="margin-percentage-inherit-001-ref.xht" />
+
+ <meta content="A margin percentage is calculated with respect to the width of the generated box's containing block. When inherit keyword is used, the property takes the same computed value - a percentage value in this testcase - as the property for the element's parent." name="assert" />
+ <meta content="image" name="flags" />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p
+ {
+ font: 1em/1.25 serif;
+ margin: 1em 0em;
+ }
+
+ div#grand-parent {width: 400px;}
+
+ div#parent
+ {
+ background-color: green;
+ border: white solid 3px;
+ /*
+ Such border prevents margin collapsing between
+ #child's vertical margin and #parent's vertical margins
+ */
+ margin: 15%; /* 15% of 400px == 60px; */
+ width: 200px;
+ }
+
+ div#child
+ {
+ margin: inherit;
+ /*
+ computes to 15% which is then applied on #child's
+ containing block width: 15% of 200px == 30px
+ */
+ }
+
+ div#abs-pos-overlapping-green
+ {
+ left: 101px;
+ position: absolute;
+ top: 149px;
+ }
+
+ /*
+ 8px (body's margin-left)
+ + 60px (#parent's margin-left)
+ + 3px (#parent's border-left)
+ + 30px (#child's margin-left)
+ ==================
+ 101px
+ */
+
+ /*
+ 16px (max(8px, 16px): body's margin-top collapses with p's margin-top)
+ + 20px (first line)
+ + 20px (second line)
+ + 60px (max(16px, 60px): p's margin-bottom collapses with #parent's margin-top)
+ + 3px (#parent's border-top)
+ + 30px (#child's margin-top)
+ ==================
+ 149px
+ */
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green<br />
+ rectangle and if there is no red.</p>
+
+ <div id="grand-parent">
+ <div id="parent">
+ <div id="child"><img src="support/100x100-red.png" alt="Image download support must be enabled" /></div>
+ </div>
+ </div>
+
+ <div id="abs-pos-overlapping-green"><img src="support/swatch-green.png" width="100" height="100" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-percentage-undefined-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-percentage-undefined-001.xht
new file mode 100644
index 0000000000..65c1380e6e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-percentage-undefined-001.xht
@@ -0,0 +1,26 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin with percentage determined by containing block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <meta name="assert" content="Potential circular reference cannot cause the user agent to crash or hang." />
+ <style type="text/css">
+ #div1
+ {
+ float: left;
+ border: 1px solid blue;
+ }
+ div div
+ {
+ margin: 50%;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if the words "Filler Text" appear below.</p>
+ <div id="div1">
+ <div>Filler Text</div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-004.xht
new file mode 100644
index 0000000000..9d9cb7090a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-004.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using pixels with a negative zero value, -0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a negative zero length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: -0px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-005.xht
new file mode 100644
index 0000000000..92207ac4a1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-005.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using pixels with a zero value, 0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a zero length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: 0px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-006.xht
new file mode 100644
index 0000000000..877506dc44
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-006.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using pixels with a positive zero value, +0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a positive zero length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: +0px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-007.xht
new file mode 100644
index 0000000000..d310ac5813
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-007.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using pixels with a nominal value, 96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-007-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+
+ #div1
+ {
+ border-right: 2px solid red;
+ float: left;
+ }
+ #div2
+ {
+ border-right: 2px solid black;
+ margin-right: -2px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-008.xht
new file mode 100644
index 0000000000..0a9c9a958a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-008.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using pixels with a nominal value with a plus sign, +96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-007-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in pixels with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 2px solid red;
+ }
+ #div1
+ {
+ margin-right: +96px;
+ }
+ #div2
+ {
+ border-right: 2px solid black;
+ margin-right: -98px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-016.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-016.xht
new file mode 100644
index 0000000000..9f18dcc359
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-016.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using points with a negative zero value, -0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a negative zero length value in points." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: -0pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-017.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-017.xht
new file mode 100644
index 0000000000..d959e2b58c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-017.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using points with a zero value, 0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a zero length value in points." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: 0pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-018.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-018.xht
new file mode 100644
index 0000000000..6c51eaad8c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-018.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using points with a positive zero value, +0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a positive zero length value in points." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: +0pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-019.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-019.xht
new file mode 100644
index 0000000000..91050afb21
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-019.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using points with a nominal value, 72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-019-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in points." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 6pt solid red;
+ }
+ #div1
+ {
+ margin-right: 72pt;
+ }
+ #div2
+ {
+ border-right: 6pt solid black;
+ margin-right: -78pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-020.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-020.xht
new file mode 100644
index 0000000000..6e06fa92e5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-020.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using points with a nominal value with a plus sign, +72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-019-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in points with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 6pt solid red;
+ }
+ #div1
+ {
+ margin-right: +72pt;
+ }
+ #div2
+ {
+ border-right: 6pt solid black;
+ margin-right: -78pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-028.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-028.xht
new file mode 100644
index 0000000000..c1c82cbe70
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-028.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using picas with a negative zero value, -0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a negative zero length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: -0pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-029.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-029.xht
new file mode 100644
index 0000000000..6c6a4bdfdd
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-029.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using picas with a zero value, 0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a zero length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: 0pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-030.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-030.xht
new file mode 100644
index 0000000000..a2c447ad5c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-030.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using picas with a positive zero value, +0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a positive zero length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: +0pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-031.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-031.xht
new file mode 100644
index 0000000000..034211c1e7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-031.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using picas with a nominal value, 6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-031-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in picas." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 1pc solid red;
+ }
+ #div1
+ {
+ margin-right: 6pc;
+ }
+ #div2
+ {
+ border-right: 1pc solid black;
+ margin-right: -7pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-032.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-032.xht
new file mode 100644
index 0000000000..de1821bae5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-032.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using picas with a nominal value with a plus sign, +6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-031-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in picas with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 1pc solid red;
+ }
+ #div1
+ {
+ margin-right: +6pc;
+ }
+ #div2
+ {
+ border-right: 1pc solid black;
+ margin-right: -7pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-040.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-040.xht
new file mode 100644
index 0000000000..551a19954e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-040.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using centimeters with a negative zero value, -0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a negative zero length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: -0cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-041.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-041.xht
new file mode 100644
index 0000000000..59f30bd5ad
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-041.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using centimeters with a zero value, 0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a zero length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: 0cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-042.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-042.xht
new file mode 100644
index 0000000000..cefe554b56
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-042.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using centimeters with a positive zero value, +0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a positive zero length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: +0cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-043.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-043.xht
new file mode 100644
index 0000000000..d042b47232
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-043.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using centimeters with a nominal value, 2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 2.54cm solid red;
+ }
+ #div1
+ {
+ margin-right: 2.54cm;
+ }
+ #div2
+ {
+ border-right: 2.54cm solid black;
+ margin-right: -5.08cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-044.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-044.xht
new file mode 100644
index 0000000000..95875d110c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-044.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using centimeters with a nominal value with a plus sign, +2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in centimeters with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 2.54cm solid red;
+ }
+ #div1
+ {
+ margin-right: +2.54cm;
+ }
+ #div2
+ {
+ border-right: 2.54cm solid black;
+ margin-right: -5.08cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-052.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-052.xht
new file mode 100644
index 0000000000..a73c68cda0
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-052.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using millimeters with a negative zero value, -0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a negative zero length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: -0mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-053.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-053.xht
new file mode 100644
index 0000000000..ca9382ddc3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-053.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using millimeters with a zero value, 0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a zero length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: 0mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-054.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-054.xht
new file mode 100644
index 0000000000..a3396cb007
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-054.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using millimeters with a positive zero value, +0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a positive zero length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: +0mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-055.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-055.xht
new file mode 100644
index 0000000000..e62776cbd1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-055.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using millimeters with a nominal value, 25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 25.4mm solid red;
+ }
+ #div1
+ {
+ margin-right: 25.4mm;
+ }
+ #div2
+ {
+ border-right: 25.4mm solid black;
+ margin-right: -50.8mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-056.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-056.xht
new file mode 100644
index 0000000000..fbc9a2ee37
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-056.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using millimeters with a nominal value with a plus sign, +25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in millimeters with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 25.4mm solid red;
+ }
+ #div1
+ {
+ margin-right: +25.4mm;
+ }
+ #div2
+ {
+ border-right: 25.4mm solid black;
+ margin-right: -50.8mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-064.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-064.xht
new file mode 100644
index 0000000000..6130e71d6e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-064.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using inches with a negative zero value, -0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a negative zero length value in inches." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: -0in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-065.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-065.xht
new file mode 100644
index 0000000000..3e288b4e01
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-065.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using inches with a zero value, 0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a zero length value in inches." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: 0in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-066.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-066.xht
new file mode 100644
index 0000000000..780fcd5873
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-066.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using inches with a positive zero value, +0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a positive zero length value in inches." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: +0in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-067.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-067.xht
new file mode 100644
index 0000000000..9976c5b120
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-067.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using inches with a nominal value, 1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-067-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in inches." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 0.25in solid red;
+ }
+ #div1
+ {
+ margin-right: 1in;
+ }
+ #div2
+ {
+ border-right: 0.25in solid black;
+ margin-right: -1.25in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-068.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-068.xht
new file mode 100644
index 0000000000..00d9287458
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-068.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using inches with a nominal value with a plus sign, +1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-067-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in inches with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 0.25in solid red;
+ }
+ #div1
+ {
+ margin-right: +1in;
+ }
+ #div2
+ {
+ border-right: 0.25in solid black;
+ margin-right: -1.25in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-076.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-076.xht
new file mode 100644
index 0000000000..aefac0a25c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-076.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using 'em' units with a negative zero value, -0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-right' property sets a negative zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: -0em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-077.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-077.xht
new file mode 100644
index 0000000000..5df88b0075
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-077.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using 'em' units with a zero value, 0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-right' property sets a zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: 0em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-078.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-078.xht
new file mode 100644
index 0000000000..c6f2f4a039
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-078.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using 'em' units with a positive zero value, +0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-right' property sets a positive zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: +0em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-079.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-079.xht
new file mode 100644
index 0000000000..35d0c41551
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-079.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using 'em' units with a nominal value, 6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ font: 20px/1 Ahem;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 1em solid red;
+ }
+ #div1
+ {
+ margin-right: 6em;
+ }
+ #div2
+ {
+ border-right: 1em solid black;
+ margin-right: -7em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-080.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-080.xht
new file mode 100644
index 0000000000..1796aedba5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-080.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using 'em' units with a nominal value with a plus sign, +6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in 'em' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ font: 20px/1 Ahem;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 1em solid red;
+ }
+ #div1
+ {
+ margin-right: +6em;
+ }
+ #div2
+ {
+ border-right: 1em solid black;
+ margin-right: -7em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-088.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-088.xht
new file mode 100644
index 0000000000..c9dbe04d7e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-088.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using 'ex' units with a negative zero value, -0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-right' property sets a negative zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: -0ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-089.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-089.xht
new file mode 100644
index 0000000000..bc97b33e22
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-089.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using 'ex' units with a zero value, 0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-right' property sets a zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: 0ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-090.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-090.xht
new file mode 100644
index 0000000000..4a8bb9052b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-090.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using 'ex' units with a positive zero value, +0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-right' property sets a positive zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: +0ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-091.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-091.xht
new file mode 100644
index 0000000000..164f4a3110
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-091.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using 'ex' units with a nominal value, 7.5ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ font: 20px/1 Ahem;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 1ex solid red;
+ }
+ #div1
+ {
+ margin-right: 7.5ex;
+ }
+ #div2
+ {
+ border-right: 1ex solid black;
+ margin-right: -8.5ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-092.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-092.xht
new file mode 100644
index 0000000000..5abb7730db
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-092.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using 'ex' units with a nominal value with a plus sign, +7.5ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in 'ex' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ font: 20px/1 Ahem;
+ height: 1in;
+ width: 0;
+ }
+ #wrapper
+ {
+ border-right: 1ex solid red;
+ }
+ #div1
+ {
+ margin-right: +7.5ex;
+ }
+ #div2
+ {
+ border-right: 1ex solid black;
+ margin-right: -8.5ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-100-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-100-ref.xht
new file mode 100644
index 0000000000..ab2ed136d9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-100-ref.xht
@@ -0,0 +1,32 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: orange;
+ border-right: blue solid 5px;
+ height: 96px;
+ left: 91px;
+ position: relative;
+ width: 5px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-100.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-100.xht
new file mode 100644
index 0000000000..88f6383f20
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-100.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using percentages with a negative zero value, -0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-right-100-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a negative zero length value in percentages." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 1in;
+ }
+ #wrapper
+ {
+ border-right: 5px solid blue;
+ }
+ #div1
+ {
+ margin-right: -0%;
+ }
+ #div2
+ {
+ border-right: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-101.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-101.xht
new file mode 100644
index 0000000000..9d65336bee
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-101.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using percentages with a zero value, 0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-right-100-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a zero length value in percentages." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 1in;
+ }
+ #wrapper
+ {
+ border-right: 5px solid blue;
+ }
+ #div1
+ {
+ margin-right: 0%;
+ }
+ #div2
+ {
+ border-right: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-102.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-102.xht
new file mode 100644
index 0000000000..18718dbe86
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-102.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using percentages with a positive zero value, +0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-right-100-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a positive zero length value in percentages." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 1in;
+ }
+ #wrapper
+ {
+ border-right: 5px solid blue;
+ }
+ #div1
+ {
+ margin-right: +0%;
+ }
+ #div2
+ {
+ border-right: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-103-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-103-ref.xht
new file mode 100644
index 0000000000..acf19ad71b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-103-ref.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 48px;
+ height: 1in;
+ left: 96px;
+ position: relative;
+ width: 500px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-103.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-103.xht
new file mode 100644
index 0000000000..347e82e987
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-103.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using percentages with a nominal value, 50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-right-103-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in percentages." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-right: 0.5in solid red;
+ width: 1in;
+ }
+ #div1
+ {
+ margin-right: 50%;
+ }
+ #div2
+ {
+ border-right: 0.5in solid black;
+ margin-right: -1in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-104.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-104.xht
new file mode 100644
index 0000000000..ec5281fff4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-104.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right using percentages with a nominal value with a plus sign, +50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-right-103-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a nominal length value in percentages with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ }
+ #wrapper
+ {
+ border-right: 0.5in solid red;
+ width: 1in;
+ }
+ #div1
+ {
+ margin-right: +50%;
+ }
+ #div2
+ {
+ border-right: 0.5in solid black;
+ margin-right: -1in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-109.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-109.xht
new file mode 100644
index 0000000000..09dc3d4198
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-109.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right sets a negative zero value with no units, -0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a negative zero length value with no units." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: -0;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-110.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-110.xht
new file mode 100644
index 0000000000..c8660723ad
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-110.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right sets a zero value with no units, 0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a zero length value with no units." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: 0;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-111.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-111.xht
new file mode 100644
index 0000000000..5857d3759b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-111.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right sets a positive zero value with no units, +0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a positive zero length value with no units." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: +0;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-112.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-112.xht
new file mode 100644
index 0000000000..10cfe7e8b4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-112.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right with a value of 'auto'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a value of 'auto'." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ margin-right: auto;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-113-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-113-ref.xht
new file mode 100644
index 0000000000..d41e39ed97
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-113-ref.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 96px;
+ height: 1in;
+ left: 96px;
+ position: relative;
+ width: 500px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-113.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-113.xht
new file mode 100644
index 0000000000..94c65354a7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-113.xht
@@ -0,0 +1,43 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right with a value of 'inherit'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-18 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-right-113-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property sets a value of 'inherit'." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 96px;
+ width: 96px;
+ }
+ #wrapper
+ {
+ border-right: 96px solid red;
+ margin-right: 48px;
+ }
+ #div1
+ {
+ margin-right: inherit;
+ }
+ #div2
+ {
+ border-right: 96px solid black;
+ margin-right: -144px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-001.xht
new file mode 100644
index 0000000000..89f0f02249
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-001.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right applied to element with display table-row-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-19 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property does not apply to elements with a display of table-row-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #table
+ {
+ display: table;
+ }
+ #test
+ {
+ display: table-row-group;
+ margin-right: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-right: 10px solid blue;
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-002.xht
new file mode 100644
index 0000000000..f3187d1453
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-002.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right applied to element with display table-header-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-19 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property does not apply to elements with a display of table-header-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #table
+ {
+ display: table;
+ }
+ #test
+ {
+ display: table-header-group;
+ margin-right: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-right: 10px solid blue;
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-003.xht
new file mode 100644
index 0000000000..b344588bc7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-003.xht
@@ -0,0 +1,53 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right applied to element with display table-footer-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-19 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property does not apply to elements with a display of table-footer-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #table
+ {
+ border-collapse: collapse;
+ display: table;
+ table-layout: fixed;
+ }
+ #test
+ {
+ display: table-footer-group;
+ margin-right: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-right: 10px solid blue;
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-004.xht
new file mode 100644
index 0000000000..3c29b163d4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-004.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right applied to element with display table-row</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-19 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property does not apply to elements with a display of table-row." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ margin-right: 50px;
+ }
+ #cell
+ {
+ border-right: 10px solid blue;
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-005.xht
new file mode 100644
index 0000000000..bfbe4aca2a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-005.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right applied to element with display table-column-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-19 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property does not apply to elements with a display of table-column-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #test
+ {
+ display: table-column-group;
+ margin-right: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-right: 10px solid blue;
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-006.xht
new file mode 100644
index 0000000000..1eb5881e50
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-006.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right applied to element with display table-column</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-19 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property does not apply to elements with a display of table-column." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #test
+ {
+ display: table-column;
+ margin-right: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-right: 10px solid blue;
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-007.xht
new file mode 100644
index 0000000000..c889e02b6a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-007.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right applied to element with display table-cell</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-19 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property does not apply to elements with a display of table-cell." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-right: 10px solid blue;
+ display: table-cell;
+ height: 200px;
+ margin-right: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-008.xht
new file mode 100644
index 0000000000..bd4b1b7ffb
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-008.xht
@@ -0,0 +1,32 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right applied to element with display inline</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-19 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <meta name="assert" content="The 'margin-right' property applies to elements with a display of inline." />
+ <style type="text/css">
+ div
+ {
+ display: inline;
+ }
+ #div1
+ {
+ border-right: 5px solid blue;
+ }
+ div div
+ {
+ border-right: 5px solid orange;
+ margin-right: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="div1">
+ <div>Filler Text</div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-009.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-009.xht
new file mode 100644
index 0000000000..a3151c16f7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-009.xht
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right applied to element with display block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-19 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property applies to elements with a display of block." />
+ <style type="text/css">
+ div
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ span
+ {
+ border-right: 10px solid blue;
+ display: block;
+ height: 200px;
+ margin-right: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div>
+ <span></span>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-010.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-010.xht
new file mode 100644
index 0000000000..af3e781a50
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-010.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right applied to element with display list-item</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-19 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <meta name="assert" content="The 'margin-right' property applies to elements with a display of list-item." />
+ <style type="text/css">
+ div
+ {
+ height: 200px;
+ direction: rtl;
+ }
+ #div1
+ {
+ border-right: 10px solid blue;
+ }
+ div div
+ {
+ border-right: 10px solid orange;
+ display: list-item;
+ margin-right: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines and there is a marker bullet between the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-012.xht
new file mode 100644
index 0000000000..a55038bde2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-012.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right applied to element with display inline-block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-19 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property applies to elements with a display of inline-block." />
+ <style type="text/css">
+ div
+ {
+ height: 200px;
+ }
+ #div1
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ div div
+ {
+ border-right: 10px solid blue;
+ display: inline-block;
+ margin-right: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-013.xht
new file mode 100644
index 0000000000..a60b39308c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-013.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right applied to element with display table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-19 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property applies to elements with a display of table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #table
+ {
+ border-right: 10px solid blue;
+ display: table;
+ margin-right: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-014.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-014.xht
new file mode 100644
index 0000000000..78b23cc919
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-014.xht
@@ -0,0 +1,46 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right applied to element with display inline-table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-19 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property applies to elements with a display of inline-table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #table
+ {
+ border-right: 10px solid blue;
+ display: inline-table;
+ margin-right: 50px;
+ vertical-align: top;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-015.xht
new file mode 100644
index 0000000000..fe22653158
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-right-applies-to-015.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-right applied to element with display table-caption</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-19 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-right' property applies to elements with a display of table-caption." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #test
+ {
+ border-right: 10px solid blue;
+ display: table-caption;
+ height: 200px;
+ margin-right: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-001-ref.xht
new file mode 100644
index 0000000000..3f548d970f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-001-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: green;
+ height: 210px;
+ width: 210px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-001.xht
new file mode 100644
index 0000000000..8deb60aacd
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-001.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin shorthand - One value application to all sides</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-shorthand-001-ref.xht" />
+
+ <meta name="flags" content="image" />
+ <meta name="assert" content="Applying a single value to the margin property replicates it to all sides of the element." />
+ <style type="text/css">
+ #div1
+ {
+ background: url('support/shorthand-001.png') -5px;
+ border: 5px green solid;
+ width: 200px;
+ }
+ div div
+ {
+ background: green;
+ margin: 20px;
+ height: 160px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-002-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-002-ref.xht
new file mode 100644
index 0000000000..a3033b1a43
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-002-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: green;
+ height: 190px;
+ width: 210px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green rectangle and <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-002.xht
new file mode 100644
index 0000000000..df6e2ddfdc
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-002.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin shorthand - Two values application top, bottom and left, right</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-shorthand-002-ref.xht" />
+
+ <meta name="flags" content="image" />
+ <meta name="assert" content="Applying two values to the margin property applies the first value to the top and bottom and the second to the left and right." />
+ <style type="text/css">
+ #div1
+ {
+ background: url('support/shorthand-002.png') -5px;
+ border: 5px green solid;
+ width: 200px;
+ }
+ div div
+ {
+ background: green;
+ margin: 10px 50px;
+ height: 160px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a filled green rectangle and <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-003-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-003-ref.xht
new file mode 100644
index 0000000000..8fbe712947
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-003-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: green;
+ height: 225px;
+ width: 210px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled green rectangle and <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-003.xht
new file mode 100644
index 0000000000..0000a18d7c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-003.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin shorthand - Three values application top and left, right and bottom</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-shorthand-003-ref.xht" />
+
+ <meta name="flags" content="image" />
+ <meta name="assert" content="Applying three values to the margin property applies the first value to the top the second value to the left and right and the third value to the bottom." />
+ <style type="text/css">
+ #div1
+ {
+ background: url('support/shorthand-003.png') -5px;
+ border: 5px green solid;
+ width: 200px;
+ }
+ div div
+ {
+ background: green;
+ margin: 5px 20px 50px;
+ height: 160px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a filled green rectangle and <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-004.xht
new file mode 100644
index 0000000000..5308f7686e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-shorthand-004.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin shorthand - four values application top, left, right, bottom</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-shorthand-003-ref.xht" />
+
+ <meta name="flags" content="image" />
+ <meta name="assert" content="Applying four values to the margin property applies the values top, right, bottom, left, respectively." />
+ <style type="text/css">
+ #div1
+ {
+ background: url('support/shorthand-004.png') -5px;
+ border: 5px green solid;
+ width: 200px;
+ }
+ div div
+ {
+ background: green;
+ margin: 5px 20px 50px 100px;
+ height: 160px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a filled green rectangle and <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-004.xht
new file mode 100644
index 0000000000..14893a0eba
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-004.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using pixels with a negative zero value, -0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a negative zero length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: -0px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-005.xht
new file mode 100644
index 0000000000..9a4df918f7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-005.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using pixels with a zero value, 0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a zero length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: 0px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-006.xht
new file mode 100644
index 0000000000..866aee1582
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-006.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using pixels with a positive zero value, +0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a positive zero length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: +0px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-007-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-007-ref.xht
new file mode 100644
index 0000000000..a61ddf99b8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-007-ref.xht
@@ -0,0 +1,24 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border-top: black solid 2px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-007.xht
new file mode 100644
index 0000000000..9466c1133f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-007.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using pixels with a nominal value, 96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-007-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 2px solid red;
+ margin-bottom: -98px;
+ }
+ #div2
+ {
+ border-top: 2px solid black;
+ margin-top: 96px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-008.xht
new file mode 100644
index 0000000000..181b3d35e2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-008.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using pixels with a nominal value with a plus sign, +96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-007-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in pixels with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 2px solid red;
+ margin-bottom: -98px;
+ }
+ #div2
+ {
+ border-top: 2px solid black;
+ margin-top: +96px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-016.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-016.xht
new file mode 100644
index 0000000000..20073525ec
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-016.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using points with a negative zero value, -0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a negative zero length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: -0pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-017.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-017.xht
new file mode 100644
index 0000000000..03cd2afccc
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-017.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using points with a zero value, 0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a zero length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: 0pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-018.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-018.xht
new file mode 100644
index 0000000000..f5ab60112a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-018.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using points with a positive zero value, +0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a positive zero length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: +0pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-019-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-019-ref.xht
new file mode 100644
index 0000000000..a3e7509622
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-019-ref.xht
@@ -0,0 +1,24 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border-top: black solid 8px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-019.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-019.xht
new file mode 100644
index 0000000000..b8f383dfa4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-019.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using points with a nominal value, 72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-019-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 6pt solid red;
+ margin-bottom: -78pt;
+ }
+ #div2
+ {
+ border-top: 6pt solid black;
+ margin-top: 72pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-020.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-020.xht
new file mode 100644
index 0000000000..9260da4066
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-020.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using points with a nominal value with a plus sign, +72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-019-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in points with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 6pt solid red;
+ margin-bottom: -78pt;
+ }
+ #div2
+ {
+ border-top: 6pt solid black;
+ margin-top: +72pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-028.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-028.xht
new file mode 100644
index 0000000000..c84cd964d4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-028.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using picas with a negative zero value, -0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a negative zero length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: -0pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-029.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-029.xht
new file mode 100644
index 0000000000..7105776f73
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-029.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using picas with a zero value, 0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a zero length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: 0pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-030.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-030.xht
new file mode 100644
index 0000000000..2b8bb60975
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-030.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using picas with a positive zero value, +0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a positive zero length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: +0pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-031-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-031-ref.xht
new file mode 100644
index 0000000000..85598a0d8e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-031-ref.xht
@@ -0,0 +1,24 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border-top: black solid 16px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-031.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-031.xht
new file mode 100644
index 0000000000..fddfc74e06
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-031.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using picas with a nominal value, 6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 1pc solid red;
+ margin-bottom: -7pc;
+ }
+ #div2
+ {
+ border-top: 1pc solid black;
+ margin-top: 6pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-032.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-032.xht
new file mode 100644
index 0000000000..114ac00b05
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-032.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using picas with a nominal value with a plus sign, +6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in picas with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 1pc solid red;
+ margin-bottom: -7pc;
+ }
+ #div2
+ {
+ border-top: 1pc solid black;
+ margin-top: +6pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-040.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-040.xht
new file mode 100644
index 0000000000..9a582cc5df
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-040.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using centimeters with a negative zero value, -0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a negative zero length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: -0cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-041.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-041.xht
new file mode 100644
index 0000000000..ef85cb43f3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-041.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using centimeters with a zero value, 0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a zero length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: 0cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-042.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-042.xht
new file mode 100644
index 0000000000..65b363bdd7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-042.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using centimeters with a positive zero value, +0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a positive zero length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: +0cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-043-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-043-ref.xht
new file mode 100644
index 0000000000..74861f67e9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-043-ref.xht
@@ -0,0 +1,24 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border-top: black solid 96px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-043.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-043.xht
new file mode 100644
index 0000000000..2dabad2c77
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-043.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using centimeters with a nominal value, 2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 2.54cm solid red;
+ margin-bottom: -5.08cm;
+ }
+ #div2
+ {
+ border-top: 2.54cm solid black;
+ margin-top: 2.54cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-044.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-044.xht
new file mode 100644
index 0000000000..d02fa3dc65
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-044.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using centimeters with a nominal value with a plus sign, +2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in centimeters with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 2.54cm solid red;
+ margin-bottom: -5.08cm;
+ }
+ #div2
+ {
+ border-top: 2.54cm solid black;
+ margin-top: +2.54cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-052.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-052.xht
new file mode 100644
index 0000000000..8bb52dcc91
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-052.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using millimeters with a negative zero value, -0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a negative zero length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: -0mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-053.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-053.xht
new file mode 100644
index 0000000000..5e65153647
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-053.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using millimeters with a zero value, 0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a zero length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: 0mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-054.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-054.xht
new file mode 100644
index 0000000000..aaeda845fc
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-054.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using millimeters with a positive zero value, +0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a positive zero length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: +0mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-055.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-055.xht
new file mode 100644
index 0000000000..5569d2eb87
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-055.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using millimeters with a nominal value, 25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 25.4mm solid red;
+ margin-bottom: -50.8mm;
+ }
+ #div2
+ {
+ border-top: 25.4mm solid black;
+ margin-top: 25.4mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-056.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-056.xht
new file mode 100644
index 0000000000..c143009a79
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-056.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using millimeters with a nominal value with a plus sign, +25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in millimeters with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 25.4mm solid red;
+ margin-bottom: -50.8mm;
+ }
+ #div2
+ {
+ border-top: 25.4mm solid black;
+ margin-top: +25.4mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-064.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-064.xht
new file mode 100644
index 0000000000..5d37faa217
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-064.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using inches with a negative zero value, -0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a negative zero length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: -0in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-065.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-065.xht
new file mode 100644
index 0000000000..8d3295456e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-065.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using inches with a zero value, 0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a zero length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: 0in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-066.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-066.xht
new file mode 100644
index 0000000000..c32d02d377
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-066.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using inches with a positive zero value, +0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a positive zero length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: +0in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-067-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-067-ref.xht
new file mode 100644
index 0000000000..2d8b45045a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-067-ref.xht
@@ -0,0 +1,24 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border-top: black solid 24px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-067.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-067.xht
new file mode 100644
index 0000000000..2e65cb75bf
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-067.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using inches with a nominal value, 1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-067-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 0.25in solid red;
+ margin-bottom: -1.25in;
+ }
+ #div2
+ {
+ border-top: 0.25in solid black;
+ margin-top: 1in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-068.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-068.xht
new file mode 100644
index 0000000000..23228ea394
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-068.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using inches with a nominal value with a plus sign, +1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-067-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in inches with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 0.25in solid red;
+ margin-bottom: -1.25in;
+ }
+ #div2
+ {
+ border-top: 0.25in solid black;
+ margin-top: +1in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-076.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-076.xht
new file mode 100644
index 0000000000..774a76a204
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-076.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using 'em' units with a negative zero value, -0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-top' property sets a negative zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: -0em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-077.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-077.xht
new file mode 100644
index 0000000000..eb2854774c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-077.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using 'em' units with a zero value, 0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-top' property sets a zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: 0em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-078.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-078.xht
new file mode 100644
index 0000000000..aec7ec86ed
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-078.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using 'em' units with a positive zero value, +0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-top' property sets a positive zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: +0em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-079-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-079-ref.xht
new file mode 100644
index 0000000000..a7e04fa9a8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-079-ref.xht
@@ -0,0 +1,24 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border-top: black solid 20px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-079.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-079.xht
new file mode 100644
index 0000000000..b80da795b5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-079.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using 'em' units with a nominal value, 6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1em solid red;
+ margin-bottom: -7em;
+ }
+ #div2
+ {
+ border-top: 1em solid black;
+ margin-top: 6em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-080.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-080.xht
new file mode 100644
index 0000000000..a9d6e79e49
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-080.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using 'em' units with a nominal value with a plus sign, +6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in 'em' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1em solid red;
+ margin-bottom: -7em;
+ }
+ #div2
+ {
+ border-top: 1em solid black;
+ margin-top: +6em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-088.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-088.xht
new file mode 100644
index 0000000000..d5035326ce
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-088.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using 'ex' units with a negative zero value, -0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-top' property sets a negative zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: -0ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-089.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-089.xht
new file mode 100644
index 0000000000..88dac0fd53
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-089.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using 'ex' units with a zero value, 0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-top' property sets a zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: 0ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-090.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-090.xht
new file mode 100644
index 0000000000..4b4bc7f66d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-090.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using 'ex' units with a positive zero value, +0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-top' property sets a positive zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: +0ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-091.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-091.xht
new file mode 100644
index 0000000000..e70ee9df3a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-091.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using 'ex' units with a nominal value, 7.5ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1ex solid red;
+ margin-bottom: -8.5ex;
+ }
+ #div2
+ {
+ border-top: 1ex solid black;
+ margin-top: 7.5ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-092.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-092.xht
new file mode 100644
index 0000000000..089a670fb1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-092.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using 'ex' units with a nominal value with a plus sign, +7.5ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in 'ex' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1ex solid red;
+ margin-bottom: -8.5ex;
+ }
+ #div2
+ {
+ border-top: 1ex solid black;
+ margin-top: +7.5ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-100.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-100.xht
new file mode 100644
index 0000000000..fea619021f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-100.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using percentages with a negative zero value, -0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-100-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a negative zero length value in percentages." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: -0%;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-101.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-101.xht
new file mode 100644
index 0000000000..9995d0ef33
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-101.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using percentages with a zero value, 0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-100-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a zero length value in percentages." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: 0%;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-102.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-102.xht
new file mode 100644
index 0000000000..361b55ecb8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-102.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using percentages with a positive zero value, +0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-100-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a positive zero length value in percentages." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: +0%;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-103-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-103-ref.xht
new file mode 100644
index 0000000000..a9877ff98e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-103-ref.xht
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-top: black solid 96px;
+ width: 192px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-103.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-103.xht
new file mode 100644
index 0000000000..fba5ffb0ef
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-103.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using percentages with a nominal value, 50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-103-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in percentages." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 2in;
+ }
+ #div1
+ {
+ border-top: 1in solid red;
+ margin-bottom: -2in;
+ }
+ #div2
+ {
+ border-top: 1in solid black;
+ margin-top: 50%;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-104.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-104.xht
new file mode 100644
index 0000000000..82ccf89ced
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-104.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top using percentages with a nominal value with a plus sign, +50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-103-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a nominal length value in percentages with a plus sign." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 2in;
+ }
+ #div1
+ {
+ border-top: 1in solid red;
+ margin-bottom: -2in;
+ }
+ #div2
+ {
+ border-top: 1in solid black;
+ margin-top: +50%;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-109.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-109.xht
new file mode 100644
index 0000000000..3a0f50f806
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-109.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top sets a negative zero value with no units, -0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a negative zero length value with no units." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: -0;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-110.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-110.xht
new file mode 100644
index 0000000000..501d74f4c1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-110.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top sets a zero value with no units, 0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a zero length value with no units." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: 0;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-111.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-111.xht
new file mode 100644
index 0000000000..8d44f9a568
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-111.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top sets a positive zero value with no units, +0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a positive zero length value with no units." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: +0;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-112.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-112.xht
new file mode 100644
index 0000000000..ee88f890d7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-112.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top with a value of 'auto'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a value of 'auto'." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ }
+ #div2
+ {
+ border-top: 5px solid orange;
+ margin-top: auto;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-113-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-113-ref.xht
new file mode 100644
index 0000000000..77dad6f312
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-113-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-top: black solid 96px;
+ position: relative;
+ top: 80px;
+ width: 192px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-113.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-113.xht
new file mode 100644
index 0000000000..b91e57ef68
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-113.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top with a value of 'inherit'</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-113-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property sets a value of 'inherit'." />
+ <style type="text/css">
+ #wrapper
+ {
+ margin-top: 1in;
+ width: 2in;
+ }
+ #div1
+ {
+ border-top: 1in solid red;
+ margin-bottom: -2in;
+ }
+ #div2
+ {
+ border-top: 1in solid black;
+ margin-top: inherit;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-001-ref.xht
new file mode 100644
index 0000000000..2314b05461
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-001-ref.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: blue;
+ height: 10px;
+ }
+
+ div + div
+ {
+ background-color: orange;
+ width: 200px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-001.xht
new file mode 100644
index 0000000000..a83e87712f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-001.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top applied to element with display table-row-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property does not apply to elements with a display of table-row-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #test
+ {
+ display: table-row-group;
+ margin-top: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-top: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-002.xht
new file mode 100644
index 0000000000..e2d5747bac
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-002.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top applied to element with display table-header-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property does not apply to elements with a display of table-header-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #test
+ {
+ display: table-header-group;
+ margin-top: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-top: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-003.xht
new file mode 100644
index 0000000000..d0036b58cc
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-003.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top applied to element with display table-footer-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property does not apply to elements with a display of table-footer-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #test
+ {
+ display: table-footer-group;
+ margin-top: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-top: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-004.xht
new file mode 100644
index 0000000000..c69c9599f2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-004.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top applied to element with display table-row</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property does not apply to elements with a display of table-row." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ margin-top: 50px;
+ }
+ #cell
+ {
+ border-top: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-005.xht
new file mode 100644
index 0000000000..61ed474c49
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-005.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top applied to element with display table-column-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property does not apply to elements with a display of table-column-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #test
+ {
+ display: table-column-group;
+ margin-top: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-top: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-006.xht
new file mode 100644
index 0000000000..2fd4cf33c4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-006.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top applied to element with display table-column</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property does not apply to elements with a display of table-column." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #test
+ {
+ display: table-column;
+ margin-top: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-top: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-007.xht
new file mode 100644
index 0000000000..4260e2dd63
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-007.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top applied to element with display table-cell</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property does not apply to elements with a display of table-cell." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-top: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ margin-top: 50px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-008.xht
new file mode 100644
index 0000000000..4724eb9798
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-008.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top applied to element with display inline</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-008-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'margin-top' property do not apply to elements with a display of inline." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ border-top: 1em solid red;
+ font: 20px/1em Ahem;
+ width: 10em;
+ }
+ div div
+ {
+ border-top: 1em solid black;
+ color: green;
+ display: inline;
+ margin-top: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div>
+ <div>XXXXXXXXXX</div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-009.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-009.xht
new file mode 100644
index 0000000000..bcb95b60e5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-009.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top applied to element with display block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-bottom-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property applies to elements with a display of block." />
+ <style type="text/css">
+ div
+ {
+ border-top: 10px solid orange;
+ }
+ span
+ {
+ border-top: 10px solid blue;
+ display: block;
+ margin-top: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div>
+ <span></span>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-010.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-010.xht
new file mode 100644
index 0000000000..324128a095
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-010.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top applied to element with display list-item</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <meta name="assert" content="The 'margin-top' property applies to elements with a display of list-item." />
+ <style type="text/css">
+ div
+ {
+ height: 200px;
+ width: 200px;
+ }
+ #div1
+ {
+ border-top: 10px solid blue;
+ margin-left: 50px;
+ }
+ div div
+ {
+ border-top: 10px solid orange;
+ display: list-item;
+ margin-top: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines and there is a marker bullet to the left-hand side of the orange line. (Note the marker bullet does not need to be aligned with either line.)</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-012-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-012-ref.xht
new file mode 100644
index 0000000000..c1247d4b24
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-012-ref.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-top: blue solid 10px;
+ border-bottom: orange solid 10px;
+ height: 50px;
+ width: 200px;
+ }
+
+ div + div
+ {
+ background-color: transparent;
+ border: none 0px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is space between the blue and orange lines.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-012.xht
new file mode 100644
index 0000000000..4be5834d9f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-012.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top applied to element with display inline-block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-applies-to-012-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property applies to elements with a display of inline-block." />
+ <style type="text/css">
+ div
+ {
+ height: 200px;
+ width: 200px;
+ }
+ #div1
+ {
+ border-top: 10px solid blue;
+ }
+ div div
+ {
+ border-top: 10px solid orange;
+ display: inline-block;
+ margin-top: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-013-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-013-ref.xht
new file mode 100644
index 0000000000..b83b4047ad
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-013-ref.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-top: blue solid 10px;
+ height: 50px;
+ }
+
+ div + div
+ {
+ border-top: orange solid 10px;
+ width: 200px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is space between the blue and orange lines.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-013.xht
new file mode 100644
index 0000000000..a6fb12b302
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-013.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top applied to element with display table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-applies-to-013-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property applies to elements with a display of table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #table
+ {
+ display: table;
+ margin-top: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-top: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-014.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-014.xht
new file mode 100644
index 0000000000..9c575e9e51
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-014.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top applied to element with display inline-table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-applies-to-013-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property applies to elements with a display of inline-table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #table
+ {
+ display: inline-table;
+ margin-top: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-top: 10px solid orange;
+ display: table-cell;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-015.xht
new file mode 100644
index 0000000000..6eb1d36db2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/margin-top-applies-to-015.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Margin-top applied to element with display table-caption</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-20 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-margin-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#margin-properties" />
+ <link rel="match" href="margin-top-applies-to-013-ref.xht" />
+
+ <meta name="assert" content="The 'margin-top' property applies to elements with a display of table-caption." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #test
+ {
+ border-top: 10px solid orange;
+ display: table-caption;
+ height: 200px;
+ margin-top: 50px;
+ width: 200px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-001.xht
new file mode 100644
index 0000000000..b7ba7f7547
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-001.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding set using a single value</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property set using a single value properly assigns the same value to all sides." />
+ <style type="text/css">
+ #wrapper
+ {
+ position: relative;
+ }
+ #div1
+ {
+ border: 10px solid green;
+ left: 0;
+ padding: 96px;
+ position: absolute;
+ top: 0;
+ }
+ #div2
+ {
+ border: 10px solid green;
+ height: 96px;
+ width: 288px;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 308px;
+ left: 0;
+ position: absolute;
+ top: 0;
+ width: 500px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-002.xht
new file mode 100644
index 0000000000..ddc1f00949
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-002.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding set using two values</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-002-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property set using two values properly assigns the first value to the top and bottom padding and the second value to the left and right padding." />
+ <style type="text/css">
+ #wrapper
+ {
+ position: relative;
+ }
+ #div1
+ {
+ border: 10px solid green;
+ left: 0;
+ padding: 96px 48px;
+ position: absolute;
+ top: 0;
+ }
+ #div2
+ {
+ border: 10px solid green;
+ height: 96px;
+ width: 288px;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 308px;
+ left: 0;
+ position: absolute;
+ top: 0;
+ width: 404px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-003.xht
new file mode 100644
index 0000000000..62850039e7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-003.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding set using three values</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-15 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-003-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property set using three values properly assigns the first value to the top padding, the second value to the left and right padding, and the third value to the bottom padding." />
+ <style type="text/css">
+ #wrapper
+ {
+ position: relative;
+ }
+ #div1
+ {
+ border: 10px solid green;
+ left: 0;
+ padding: 96px 48px 192px;
+ position: absolute;
+ top: 0;
+ }
+ #div2
+ {
+ border: 10px solid green;
+ height: 96px;
+ width: 288px;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 404px;
+ left: 0;
+ position: absolute;
+ top: 0;
+ width: 404px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-004-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-004-ref.xht
new file mode 100644
index 0000000000..7c6fbfabab
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-004-ref.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border: green solid 10px;}
+
+ div#wrapper
+ {
+ height: 284px;
+ width: 380px;
+ }
+
+ div#inner
+ {
+ height: 96px;
+ left: 24px;
+ position: relative;
+ top: 96px;
+ width: 288px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div id="wrapper">
+ <div id="inner"></div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-004.xht
new file mode 100644
index 0000000000..ecc7575c84
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-004.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding set using four values</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property set using three values properly assigns the first value to the top padding, the second value to the left padding, the third value to the bottom padding, and the fourth value to the right padding." />
+ <style type="text/css">
+ #wrapper
+ {
+ position: relative;
+ }
+ #div1
+ {
+ border: 10px solid green;
+ left: 0;
+ padding: 96px 48px 72px 24px;
+ position: absolute;
+ top: 0;
+ }
+ #div2
+ {
+ border: 10px solid green;
+ height: 96px;
+ width: 288px;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 284px;
+ left: 0;
+ position: absolute;
+ top: 0;
+ width: 380px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-005-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-005-ref.xht
new file mode 100644
index 0000000000..8d9be5c56e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-005-ref.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border: green solid 10px;}
+
+ div#wrapper
+ {
+ height: 308px;
+ width: 500px;
+ }
+
+ div#inner
+ {
+ height: 96px;
+ left: 96px;
+ position: relative;
+ top: 96px;
+ width: 288px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div id="wrapper">
+ <div id="inner"></div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-005.xht
new file mode 100644
index 0000000000..45adfaa116
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-005.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding inheriting one value</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-005-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property set to 'inherit' and inheriting one value." />
+ <style type="text/css">
+ #wrapper
+ {
+ padding: 96px;
+ position: relative;
+ }
+ #div1
+ {
+ border: 10px solid green;
+ left: 0;
+ padding: inherit;
+ position: absolute;
+ top: 0;
+ }
+ #div2
+ {
+ border: 10px solid green;
+ height: 96px;
+ width: 288px;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 308px;
+ left: 0;
+ position: absolute;
+ top: 0;
+ width: 500px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-006-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-006-ref.xht
new file mode 100644
index 0000000000..e648286bed
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-006-ref.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border: green solid 10px;}
+
+ div#wrapper
+ {
+ height: 308px;
+ width: 356px;
+ }
+
+ div#inner
+ {
+ height: 96px;
+ left: 24px;
+ position: relative;
+ top: 96px;
+ width: 288px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div id="wrapper">
+ <div id="inner"></div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-006.xht
new file mode 100644
index 0000000000..f112a493e8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-006.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding inheriting two values</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-006-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property set to 'inherit' and inheriting two values." />
+ <style type="text/css">
+ #wrapper
+ {
+ padding: 96px 24px;
+ position: relative;
+ }
+ #div1
+ {
+ border: 10px solid green;
+ left: 0;
+ padding: inherit;
+ position: absolute;
+ top: 0;
+ }
+ #div2
+ {
+ border: 10px solid green;
+ height: 96px;
+ width: 288px;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 308px;
+ left: 0;
+ position: absolute;
+ top: 0;
+ width: 356px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-007-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-007-ref.xht
new file mode 100644
index 0000000000..78753d68c2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-007-ref.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border: green solid 10px;}
+
+ div#wrapper
+ {
+ height: 284px;
+ width: 356px;
+ }
+
+ div#inner
+ {
+ height: 96px;
+ left: 24px;
+ position: relative;
+ top: 96px;
+ width: 288px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div id="wrapper">
+ <div id="inner"></div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-007.xht
new file mode 100644
index 0000000000..eb05e281b2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-007.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding inheriting three values</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property set to 'inherit' and inheriting three values." />
+ <style type="text/css">
+ #wrapper
+ {
+ padding: 96px 24px 72px;
+ position: relative;
+ }
+ #div1
+ {
+ border: 10px solid green;
+ left: 0;
+ padding: inherit;
+ position: absolute;
+ top: 0;
+ }
+ #div2
+ {
+ border: 10px solid green;
+ height: 96px;
+ width: 288px;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 284px;
+ left: 0;
+ position: absolute;
+ top: 0;
+ width: 356px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-008-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-008-ref.xht
new file mode 100644
index 0000000000..9844e95116
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-008-ref.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border: green solid 10px;}
+
+ div#wrapper
+ {
+ height: 284px;
+ width: 380px;
+ }
+
+ div#inner
+ {
+ height: 96px;
+ left: 48px;
+ position: relative;
+ top: 96px;
+ width: 288px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div id="wrapper">
+ <div id="inner"></div>
+ </div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-008.xht
new file mode 100644
index 0000000000..e569c8ae0f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-008.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding inheriting four values</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-008-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property set to 'inherit' and inheriting four values." />
+ <style type="text/css">
+ #wrapper
+ {
+ padding: 96px 24px 72px 48px;
+ position: relative;
+ }
+ #div1
+ {
+ border: 10px solid green;
+ left: 0;
+ padding: inherit;
+ position: absolute;
+ top: 0;
+ }
+ #div2
+ {
+ border: 10px solid green;
+ height: 96px;
+ width: 288px;
+ }
+ #reference
+ {
+ border: 10px solid red;
+ height: 284px;
+ left: 0;
+ position: absolute;
+ top: 0;
+ width: 380px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="reference"></div>
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-009-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-009-ref.xht
new file mode 100644
index 0000000000..7cb24dda85
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-009-ref.xht
@@ -0,0 +1,22 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border: green solid 8px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <div>Test passes if this sentence has a <strong>green border</strong>.</div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-009.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-009.xht
new file mode 100644
index 0000000000..89fa5e02f8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-009.xht
@@ -0,0 +1,24 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: CSS Parsing: Negative Padding</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/parsing/001.xml" type="application/xhtml+xml"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/syndata.html#length-units" />
+ <link rel="match" href="padding-009-ref.xht" />
+
+ <meta name="flags" content="invalid"/>
+ <style type="text/css">
+ .test { background: green; padding: 8px; padding: -8px; display: block; }
+ .test > .inner { background: white; display: block; }
+ </style>
+ </head>
+ <body>
+ <div class="test">
+ <div class="inner">
+ Test passes if this sentence has a <strong>green border</strong>.
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-001.xht
new file mode 100644
index 0000000000..91560d4124
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-001.xht
@@ -0,0 +1,53 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding applied to element with display table-row-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property does not apply to elements with a display of table-row-group." />
+ <style type="text/css">
+ #test
+ {
+ display: table-row-group;
+ padding: 50px;
+ }
+ #table
+ {
+ border: 10px solid blue;
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border: 10px solid orange;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-002.xht
new file mode 100644
index 0000000000..cc67c4c062
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-002.xht
@@ -0,0 +1,53 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding applied to element with display table-header-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property does not apply to elements with a display of table-header-group." />
+ <style type="text/css">
+ #test
+ {
+ display: table-header-group;
+ padding: 50px;
+ }
+ #table
+ {
+ border: 10px solid blue;
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border: 10px solid orange;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-003.xht
new file mode 100644
index 0000000000..2e12fdfdf9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-003.xht
@@ -0,0 +1,53 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding applied to element with display table-footer-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property does not apply to elements with a display of table-footer-group." />
+ <style type="text/css">
+ #test
+ {
+ display: table-footer-group;
+ padding: 50px;
+ }
+ #table
+ {
+ border: 10px solid blue;
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border: 10px solid orange;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-004.xht
new file mode 100644
index 0000000000..1caa714c82
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-004.xht
@@ -0,0 +1,47 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding applied to element with display table-row</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property does not apply to elements with a display of table-row." />
+ <style type="text/css">
+ #table
+ {
+ border: 10px solid blue;
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ padding: 50px;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border: 10px solid orange;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-005.xht
new file mode 100644
index 0000000000..2feb87d662
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-005.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding applied to element with display table-column-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property does not apply to elements with a display of table-column-group." />
+ <style type="text/css">
+ #test
+ {
+ display: table-column-group;
+ padding: 50px;
+ }
+ #table
+ {
+ border: 10px solid blue;
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border: 10px solid orange;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-006.xht
new file mode 100644
index 0000000000..f85c3a3079
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-006.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding applied to element with display table-column</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property does not apply to elements with a display of table-column." />
+ <style type="text/css">
+ #test
+ {
+ display: table-column;
+ padding: 50px;
+ }
+ #table
+ {
+ border: 10px solid blue;
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border: 10px solid orange;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-007.xht
new file mode 100644
index 0000000000..9f57bf5158
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-007.xht
@@ -0,0 +1,47 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding applied to element with display table-cell</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property applies to elements with a display of table-cell." />
+ <style type="text/css">
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border: 10px solid blue;
+ display: table-cell;
+ padding: 50px;
+ }
+ #cell div
+ {
+ border: 10px solid orange;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines on all four sides.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-008.xht
new file mode 100644
index 0000000000..feccd458e6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-008.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding applied to element with display inline</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <!-- link rel="match" href="padding-applies-to-008-ref.xht" / -->
+
+ <meta name="assert" content="The 'padding' property applies to elements with a display of inline." />
+ <style type="text/css">
+ p
+ {
+ margin-bottom: 100px;
+ }
+ div
+ {
+ display: inline;
+ }
+ #div1
+ {
+ border: 10px solid blue;
+ padding: 50px;
+ }
+ div div
+ {
+ border: 10px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines on all four sides.</p>
+ <div id="div1">
+ <div>Filler Text</div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-009.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-009.xht
new file mode 100644
index 0000000000..ce5e24e8ab
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-009.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding applied to element with display block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property applies to elements with a display of block." />
+ <style type="text/css">
+ span
+ {
+ display: block;
+ }
+ #span1
+ {
+ border: 10px solid blue;
+ padding: 50px;
+ width: 220px;
+ }
+ span span
+ {
+ border: 10px solid orange;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines on all four sides.</p>
+ <div>
+ <span id="span1">
+ <span></span>
+ </span>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-010.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-010.xht
new file mode 100644
index 0000000000..3c764ba43b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-010.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding applied to element with display list-item</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <meta name="assert" content="The 'padding' property applies to elements with a display of list-item." />
+ <style type="text/css">
+ body
+ {
+ margin-left: 50px;
+ }
+ #div1
+ {
+ border: 10px solid blue;
+ display: list-item;
+ padding: 50px;
+ width: 220px;
+ }
+ div div
+ {
+ border: 10px solid orange;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines on all four sides and there is a marker bullet on the left-hand side of the blue box.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-012.xht
new file mode 100644
index 0000000000..a35ea41fc1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-012.xht
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding applied to element with display inline-block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property applies to elements with a display of inline-block." />
+ <style type="text/css">
+ #div1
+ {
+ border: 10px solid blue;
+ display: inline-block;
+ padding: 50px;
+ width: 220px;
+ }
+ div div
+ {
+ border: 10px solid orange;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines on all four sides.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-013.xht
new file mode 100644
index 0000000000..212357e362
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-013.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding applied to element with display table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property applies to elements with a display of table." />
+ <style type="text/css">
+ #table
+ {
+ border: 10px solid blue;
+ display: table;
+ padding: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border: 10px solid orange;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines on all four sides.</p>
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-014.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-014.xht
new file mode 100644
index 0000000000..a6d84c620c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-014.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding applied to element with display inline-table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property applies to elements with a display of inline-table." />
+ <style type="text/css">
+ #table
+ {
+ border: 10px solid blue;
+ display: inline-table;
+ padding: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border: 10px solid orange;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines on all four sides.</p>
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-015.xht
new file mode 100644
index 0000000000..003afe85ca
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-015.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding applied to element with display table-caption</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding' property applies to elements with a display of table-caption." />
+ <style type="text/css">
+ #table
+ {
+ display: table;
+ }
+ #test
+ {
+ border: 10px solid blue;
+ display: table-caption;
+ padding: 50px;
+ width: 220px;
+ }
+ #test div
+ {
+ border: 10px solid orange;
+ height: 200px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines on all four sides.</p>
+ <div id="table">
+ <div id="test">
+ <div></div>
+ </div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-016.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-016.xht
new file mode 100644
index 0000000000..7023f79cd1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-016.xht
@@ -0,0 +1,32 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: CSS Tables: Bottom Padding on Inline Children</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Elika J. Etemad" href="http://fantasai.inkedblade.net/contact"/>
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/table/013.xml" type="application/xhtml+xml"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+
+ <style type="text/css">
+ /* reset everything to be sure we don't introduce oddities */
+ table { border: 0; border-spacing: 0; padding: 0; margin: 0; line-height: 1; }
+ td { border: 0; padding: 0; margin: 0; line-height: 1; }
+ span { border: 0; padding: 0; margin: 0; line-height: 1; display: inline; }
+
+ /* the test */
+ body { margin-top: 12em; }
+ table { background: red; }
+ span.control { background: green; color: white; }
+ span.test { padding-top: 10em; }
+ </style>
+ </head>
+ <body>
+ <table>
+ <tr>
+ <td>
+ <span class="test"><span class="control">There should be no red on this page.</span></span>
+ </td>
+ </tr>
+ </table>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-017.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-017.xht
new file mode 100644
index 0000000000..8ff267c081
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-applies-to-017.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: CSS Tables: Bottom Padding on Inline Children</title>
+ <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/>
+ <link rel="reviewer" title="Elika J. Etemad" href="http://fantasai.inkedblade.net/contact" />
+ <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/table/012.xml" type="application/xhtml+xml"/>
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+
+ <style type="text/css">
+ /* reset everything to be sure we don't introduce oddities */
+ table { border: 0; border-spacing: 0; padding: 0; margin: 0; line-height: 1; }
+ td { border: 0; padding: 0; margin: 0; line-height: 1; }
+ span { border: 0; padding: 0; margin: 0; line-height: 1; display: inline; }
+
+ /* the test */
+ table { background: red; }
+ span.control { background: green; color: white; }
+ span.test { padding-bottom: 10em; }
+ </style>
+ </head>
+ <body>
+ <table>
+ <tr>
+ <td>
+ <span class="test"><span class="control">There should be no red on this page.</span></span>
+ </td>
+ </tr>
+ </table>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-background-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-background-001-ref.xht
new file mode 100644
index 0000000000..0a61ae59e2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-background-001-ref.xht
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: green;
+ height: 100px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a wide filled green rectangle.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-background-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-background-001.xht
new file mode 100644
index 0000000000..5397238d76
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-background-001.xht
@@ -0,0 +1,23 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding background defined by the background property</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-21 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-background-001-ref.xht" />
+
+ <meta name="assert" content="The background for the padding area is defined by the background property." />
+ <style type="text/css">
+ div
+ {
+ background: green;
+ padding: 50px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a wide filled green rectangle.</p>
+ <div></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-001.xht
new file mode 100644
index 0000000000..acf32d0de8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-001.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using pixels with a minimum minus one value, -1px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum minus one length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -1px;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-002.xht
new file mode 100644
index 0000000000..ef6e61af5f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-002.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using pixels with a minimum value, 0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: 0px;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-003.xht
new file mode 100644
index 0000000000..fce14632ae
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-003.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using pixels with a minimum plus one value, 1px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum plus one length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 2px solid red;
+ padding-bottom: 1px;
+ }
+ #div2
+ {
+ border-bottom: 2px solid black;
+ margin-top: -3px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-004.xht
new file mode 100644
index 0000000000..095779732b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-004.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using pixels with a negative zero value, -0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a negative zero length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -0px;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-005.xht
new file mode 100644
index 0000000000..3c4a612a19
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-005.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using pixels with a positive zero value, +0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a positive zero length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: +0px;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-006.xht
new file mode 100644
index 0000000000..a98d8798ef
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-006.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using pixels with a nominal value, 96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 2px solid red;
+ padding-bottom: 96px;
+ }
+ #div2
+ {
+ border-bottom: 2px solid black;
+ margin-top: -98px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-007.xht
new file mode 100644
index 0000000000..9aa75073ca
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-007.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using pixels with a nominal value with a plus sign, +96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in pixels with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 2px solid red;
+ padding-bottom: +96px;
+ }
+ #div2
+ {
+ border-bottom: 2px solid black;
+ margin-top: -98px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-012.xht
new file mode 100644
index 0000000000..958ca6b5f3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-012.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using points with a minimum minus one value, -1pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum minus one length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -1pt;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-013.xht
new file mode 100644
index 0000000000..5520e5d9f3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-013.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using points with a minimum value, 0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: 0pt;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-014.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-014.xht
new file mode 100644
index 0000000000..be8ad86a73
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-014.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using points with a minimum plus one value, 1pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum plus one length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 72pt solid red;
+ padding-bottom: 1pt;
+ }
+ #div2
+ {
+ border-bottom: 72pt solid black;
+ margin-top: -73pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-015.xht
new file mode 100644
index 0000000000..2b4c74c843
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-015.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using points with a negative zero value, -0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a negative zero length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -0pt;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-016.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-016.xht
new file mode 100644
index 0000000000..b53af3774c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-016.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using points with a positive zero value, +0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a positive zero length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: +0pt;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-017.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-017.xht
new file mode 100644
index 0000000000..9738660639
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-017.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using points with a nominal value, 72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-019-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 6pt solid red;
+ padding-bottom: 72pt;
+ }
+ #div2
+ {
+ border-bottom: 6pt solid black;
+ margin-top: -78pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-018.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-018.xht
new file mode 100644
index 0000000000..1edbff3f5d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-018.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using points with a nominal value with a plus sign, +72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-019-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in points with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 6pt solid red;
+ padding-bottom: +72pt;
+ }
+ #div2
+ {
+ border-bottom: 6pt solid black;
+ margin-top: -78pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-023.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-023.xht
new file mode 100644
index 0000000000..6d34f4ba3f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-023.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using picas with a minimum minus one value, -1pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum minus one length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -1pc;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-024.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-024.xht
new file mode 100644
index 0000000000..d599bdc36b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-024.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using picas with a minimum value, 0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: 0pc;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-025.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-025.xht
new file mode 100644
index 0000000000..c72582e38b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-025.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using picas with a minimum plus one value, 1pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum plus one length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 1pc solid red;
+ padding-bottom: 1pc;
+ }
+ #div2
+ {
+ border-bottom: 1pc solid black;
+ margin-top: -2pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-026.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-026.xht
new file mode 100644
index 0000000000..181394b6da
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-026.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using picas with a negative zero value, -0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a negative zero length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -0pc;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-027.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-027.xht
new file mode 100644
index 0000000000..2412532977
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-027.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using picas with a positive zero value, +0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a positive zero length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: +0pc;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-028.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-028.xht
new file mode 100644
index 0000000000..bbad8fc844
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-028.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using picas with a nominal value, 6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 1pc solid red;
+ padding-bottom: 6pc;
+ }
+ #div2
+ {
+ border-bottom: 1pc solid black;
+ margin-top: -7pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-029.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-029.xht
new file mode 100644
index 0000000000..677da2e7ce
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-029.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using picas with a nominal value with a plus sign, +6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in picas with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 1pc solid red;
+ padding-bottom: +6pc;
+ }
+ #div2
+ {
+ border-bottom: 1pc solid black;
+ margin-top: -7pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-034.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-034.xht
new file mode 100644
index 0000000000..abd80c753e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-034.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using centimeters with a minimum minus one value, -1cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum minus one length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -1cm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-035.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-035.xht
new file mode 100644
index 0000000000..cf72bf7364
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-035.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using centimeters with a minimum value, 0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: 0cm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-036.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-036.xht
new file mode 100644
index 0000000000..ab6935022d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-036.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using centimeters with a minimum plus one value, 1cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum plus one length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 0;
+ width: 50px;
+ }
+ .parent1
+ {
+ background: red;
+ min-height: 37px
+ }
+ .test1, .test2
+ {
+ padding-bottom: 1cm;
+ }
+ .test1
+ {
+ background: green;
+ }
+ .test2
+ {
+ background: red;
+ }
+ .child1
+ {
+ background: green;
+ height: 38px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div class="parent1">
+ <div class="test1"></div>
+ </div>
+ <div class="test2">
+ <div class="child1"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-037.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-037.xht
new file mode 100644
index 0000000000..a789195c6e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-037.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using centimeters with a negative zero value, -0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a negative zero length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -0cm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-038.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-038.xht
new file mode 100644
index 0000000000..5cd9a16669
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-038.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using centimeters with a positive zero value, +0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a positive zero length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: +0cm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-039.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-039.xht
new file mode 100644
index 0000000000..98b0af5f32
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-039.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using centimeters with a nominal value, 2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 2.54cm solid red;
+ padding-bottom: 2.54cm;
+ }
+ #div2
+ {
+ border-bottom: 2.54cm solid black;
+ margin-top: -5.08cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-040.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-040.xht
new file mode 100644
index 0000000000..1e857f6ee4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-040.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using centimeters with a nominal value with a plus sign, +2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in centimeters with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 2.54cm solid red;
+ padding-bottom: +2.54cm;
+ }
+ #div2
+ {
+ border-bottom: 2.54cm solid black;
+ margin-top: -5.08cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-045.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-045.xht
new file mode 100644
index 0000000000..eced25f9f4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-045.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using millimeters with a minimum minus one value, -1mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum minus one length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -1mm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-046.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-046.xht
new file mode 100644
index 0000000000..9beff81862
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-046.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using millimeters with a minimum value, 0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: 0mm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-047.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-047.xht
new file mode 100644
index 0000000000..92c21fa9ed
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-047.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using millimeters with a minimum plus one value, 1mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum plus one length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 0;
+ width: 50px;
+ }
+ .parent1
+ {
+ background: red;
+ min-height: 3px
+ }
+ .test1, .test2
+ {
+ padding-bottom: 1mm;
+ }
+ .test1
+ {
+ background: green;
+ }
+ .test2
+ {
+ background: red;
+ }
+ .child1
+ {
+ background: green;
+ height: 4px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div class="parent1">
+ <div class="test1"></div>
+ </div>
+ <div class="test2">
+ <div class="child1"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-048.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-048.xht
new file mode 100644
index 0000000000..a78ec26daa
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-048.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using millimeters with a negative zero value, -0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a negative zero length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -0mm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-049.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-049.xht
new file mode 100644
index 0000000000..419cc1ff56
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-049.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using millimeters with a positive zero value, +0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a positive zero length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: +0mm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-050.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-050.xht
new file mode 100644
index 0000000000..e96ed0551e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-050.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using millimeters with a nominal value, 25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 25.4mm solid red;
+ padding-bottom: 25.4mm;
+ }
+ #div2
+ {
+ border-bottom: 25.4mm solid black;
+ margin-top: -50.8mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-051.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-051.xht
new file mode 100644
index 0000000000..8324524992
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-051.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using millimeters with a nominal value with a plus sign, +25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in millimeters with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 25.4mm solid red;
+ padding-bottom: +25.4mm;
+ }
+ #div2
+ {
+ border-bottom: 25.4mm solid black;
+ margin-top: -50.8mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-056.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-056.xht
new file mode 100644
index 0000000000..6610354be3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-056.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using inches with a minimum minus one value, -1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum minus one length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -1in;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-057.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-057.xht
new file mode 100644
index 0000000000..5103f296b8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-057.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using inches with a minimum value, 0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: 0in;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-058.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-058.xht
new file mode 100644
index 0000000000..68e33571fc
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-058.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using inches with a minimum plus one value, 1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum plus one length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 1in solid red;
+ padding-bottom: 1in;
+ }
+ #div2
+ {
+ border-bottom: 1in solid black;
+ margin-top: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-059.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-059.xht
new file mode 100644
index 0000000000..516a6ed79b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-059.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using inches with a negative zero value, -0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a negative zero length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -0in;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-060.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-060.xht
new file mode 100644
index 0000000000..450a54daaf
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-060.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using inches with a positive zero value, +0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a positive zero length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: +0in;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-061.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-061.xht
new file mode 100644
index 0000000000..9174440386
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-061.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using inches with a nominal value, 3in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 1in solid red;
+ padding-bottom: 3in;
+ }
+ #div2
+ {
+ border-bottom: 1in solid black;
+ margin-top: -4in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-062.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-062.xht
new file mode 100644
index 0000000000..3d9cf3438f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-062.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using inches with a nominal value with a plus sign, +3in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in inches with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 1in solid red;
+ padding-bottom: +3in;
+ }
+ #div2
+ {
+ border-bottom: 1in solid black;
+ margin-top: -4in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-067.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-067.xht
new file mode 100644
index 0000000000..49c2d41c6d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-067.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using 'em' units with a minimum minus one value, -1em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem invalid" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum minus one length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -1em;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-068.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-068.xht
new file mode 100644
index 0000000000..776bc25807
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-068.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using 'em' units with a minimum value, 0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: 0em;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-069.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-069.xht
new file mode 100644
index 0000000000..7df3130ee9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-069.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using 'em' units with a minimum plus one value, 1em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum plus one length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1em solid red;
+ padding-bottom: 1em;
+ }
+ #div2
+ {
+ border-bottom: 1em solid black;
+ margin-top: -2em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-070.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-070.xht
new file mode 100644
index 0000000000..70955d4c17
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-070.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using 'em' units with a negative zero value, -0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-bottom' property handles a negative zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -0em;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-071.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-071.xht
new file mode 100644
index 0000000000..9dc787f7fb
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-071.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using 'em' units with a positive zero value, +0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-bottom' property handles a positive zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: +0em;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-072.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-072.xht
new file mode 100644
index 0000000000..a572f6c663
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-072.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using 'em' units with a nominal value, 6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1em solid red;
+ padding-bottom: 6em;
+ }
+ #div2
+ {
+ border-bottom: 1em solid black;
+ margin-top: -7em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-073.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-073.xht
new file mode 100644
index 0000000000..e2ea82a38b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-073.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using 'em' units with a nominal value with a plus sign, +6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in 'em' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1em solid red;
+ padding-bottom: +6em;
+ }
+ #div2
+ {
+ border-bottom: 1em solid black;
+ margin-top: -7em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-078.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-078.xht
new file mode 100644
index 0000000000..5df63cf885
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-078.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using 'ex' units with a minimum minus one value, -1ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem invalid" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum minus one length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -1ex;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-079.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-079.xht
new file mode 100644
index 0000000000..8cde7fc7c2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-079.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using 'ex' units with a minimum value, 0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: 0ex;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-080.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-080.xht
new file mode 100644
index 0000000000..63eed6d889
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-080.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using 'ex' units with a minimum plus one value, 1ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum plus one length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1ex solid red;
+ padding-bottom: 1ex;
+ }
+ #div2
+ {
+ border-bottom: 1ex solid black;
+ margin-top: -2ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-081.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-081.xht
new file mode 100644
index 0000000000..5d2d85f362
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-081.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using 'ex' units with a negative zero value, -0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-bottom' property handles a negative zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -0ex;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-082.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-082.xht
new file mode 100644
index 0000000000..da8ecbe0d1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-082.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using 'ex' units with a positive zero value, +0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-bottom' property handles a positive zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: +0ex;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-083.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-083.xht
new file mode 100644
index 0000000000..4bc75f179c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-083.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using 'ex' units with a nominal value, 7.5ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1ex solid red;
+ padding-bottom: 7.5ex;
+ }
+ #div2
+ {
+ border-bottom: 1ex solid black;
+ margin-top: -8.5ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-084.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-084.xht
new file mode 100644
index 0000000000..b9de3ae641
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-084.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using 'ex' units with a nominal value with a plus sign, +7.5ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in 'ex' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1ex solid red;
+ padding-bottom: +7.5ex;
+ }
+ #div2
+ {
+ border-bottom: 1ex solid black;
+ margin-top: -8.5ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-089.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-089.xht
new file mode 100644
index 0000000000..3bce6e17a9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-089.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using percentage with a minimum minus one value, -1%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-bottom-100-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum minus one length value in percentage." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -1%;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-090.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-090.xht
new file mode 100644
index 0000000000..71bae181ab
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-090.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using percentage with a minimum value, 0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-bottom-100-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum length value in percentage." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: 0%;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-091-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-091-ref.xht
new file mode 100644
index 0000000000..2194b5e076
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-091-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: black;
+ height: 10px;
+ width: 600px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-091.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-091.xht
new file mode 100644
index 0000000000..037155bca5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-091.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using percentage with a minimum plus one value, 1%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-bottom-091-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a minimum plus one length value in percentage." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 600px;
+ }
+ #div1
+ {
+ border-top: 10px solid red;
+ padding-bottom: 1%;
+ }
+ #div2
+ {
+ border-bottom: 10px solid black;
+ margin-top: -16px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-092.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-092.xht
new file mode 100644
index 0000000000..2c16710030
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-092.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using percentage with a negative zero value, -0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-bottom-100-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a negative zero length value in percentage." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -0%;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-093.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-093.xht
new file mode 100644
index 0000000000..b20f2e7867
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-093.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using percentage with a positive zero value, +0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-bottom-100-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a positive zero length value in percentage." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: +0%;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-094.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-094.xht
new file mode 100644
index 0000000000..a1159abafa
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-094.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using percentage with a nominal value, 50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-103-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in percentage." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 2in;
+ }
+ #div1
+ {
+ border-top: 1in solid red;
+ padding-bottom: 50%;
+ }
+ #div2
+ {
+ border-bottom: 1in solid black;
+ margin-top: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-095.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-095.xht
new file mode 100644
index 0000000000..459a25e2c6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-095.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using percentage with a nominal value with a plus sign, +50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-103-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a nominal length value in percentage with a plus sign." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 2in;
+ }
+ #div1
+ {
+ border-top: 1in solid red;
+ padding-bottom: +50%;
+ }
+ #div2
+ {
+ border-bottom: 1in solid black;
+ margin-top: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-100.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-100.xht
new file mode 100644
index 0000000000..8664959de2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-100.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom with a negative zero value and no units, -0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a negative zero length value with no units." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: -0;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-101.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-101.xht
new file mode 100644
index 0000000000..4b1ac64eb1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-101.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom with a zero value and no units, 0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a zero length value with no units." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: 0;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-102.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-102.xht
new file mode 100644
index 0000000000..2f262d96fb
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-102.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom with a positive zero value and no units, +0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles a positive zero length value with no units." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-bottom: +0;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-103-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-103-ref.xht
new file mode 100644
index 0000000000..d9cd639079
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-103-ref.xht
@@ -0,0 +1,24 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div {border-bottom: black solid 96px;}
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-103.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-103.xht
new file mode 100644
index 0000000000..1419229589
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-103.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom using the 'inherit' value</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-bottom-103-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property handles the 'inherit' value." />
+ <style type="text/css">
+ #wrapper
+ {
+ padding-bottom: 1in;
+ }
+ #div1
+ {
+ border-top: 1in solid red;
+ padding-bottom: inherit;
+ }
+ #div2
+ {
+ border-bottom: 1in solid black;
+ margin-top: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-001-ref.xht
new file mode 100644
index 0000000000..3e2978551f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-001-ref.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: orange;
+ height: 10px;
+ width: 200px;
+ }
+
+ div + div
+ {
+ background-color: blue;
+ width: auto;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-001.xht
new file mode 100644
index 0000000000..b47297ae49
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-001.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom applied to element with display table-row-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-bottom-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property does not apply to elements with a display of table-row-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #test
+ {
+ display: table-row-group;
+ padding-bottom: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-bottom: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-002.xht
new file mode 100644
index 0000000000..555cd7b804
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-002.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom applied to element with display table-header-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-bottom-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property does not apply to elements with a display of table-header-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #test
+ {
+ display: table-header-group;
+ padding-bottom: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-bottom: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-003.xht
new file mode 100644
index 0000000000..f5f07ddd30
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-003.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom applied to element with display table-footer-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-bottom-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property does not apply to elements with a display of table-footer-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #test
+ {
+ display: table-footer-group;
+ padding-bottom: 50px;
+ }
+ #table
+ {
+ display: table;
+ table-layout: fixed;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-bottom: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-004.xht
new file mode 100644
index 0000000000..58fae89ea0
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-004.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom applied to element with display table-row</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-bottom-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property does not apply to elements with a display of table-row." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ padding-bottom: 50px;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-bottom: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-005.xht
new file mode 100644
index 0000000000..53e35b9753
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-005.xht
@@ -0,0 +1,54 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom applied to element with display table-column-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-bottom-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property does not apply to elements with a display of table-column-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #test
+ {
+ display: table-column-group;
+ padding-bottom: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-bottom: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-006.xht
new file mode 100644
index 0000000000..dbbd39b088
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-006.xht
@@ -0,0 +1,54 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom applied to element with display table-column</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-bottom-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property does not apply to elements with a display of table-column." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ }
+ #test
+ {
+ display: table-column;
+ padding-bottom: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-bottom: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-007-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-007-ref.xht
new file mode 100644
index 0000000000..f9ccba0dbf
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-007-ref.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: orange;
+ height: 10px;
+ width: 200px;
+ }
+
+ div + div
+ {
+ background-color: blue;
+ margin-top: 50px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is space between the blue and orange lines.</p>
+
+ <div></div>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-007.xht
new file mode 100644
index 0000000000..ab79f2b7d7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-007.xht
@@ -0,0 +1,44 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom applied to element with display table-cell</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-bottom-applies-to-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property applies to elements with a display of table-cell." />
+ <style type="text/css">
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-bottom: 10px solid blue;
+ display: table-cell;
+ padding-bottom: 50px;
+ }
+ #cell div
+ {
+ border-bottom: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-008.xht
new file mode 100644
index 0000000000..1bff77fc6e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-008.xht
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom applied to element with display inline</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+
+ <meta name="assert" content="The 'padding-bottom' property applies to elements with a display of inline." />
+ <style type="text/css">
+ div
+ {
+ display: inline;
+ }
+ #div1
+ {
+ border-bottom: 5px solid blue;
+ padding-bottom: 50px;
+ }
+ div div
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="div1">
+ <div>Filler Text</div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-009.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-009.xht
new file mode 100644
index 0000000000..ecfd1c075e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-009.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom applied to element with display block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-bottom-applies-to-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property applies to elements with a display of block." />
+ <style type="text/css">
+ span
+ {
+ display: block;
+ width: 200px;
+ }
+ #span1
+ {
+ border-bottom: 10px solid blue;
+ padding-bottom: 50px;
+ }
+ span span
+ {
+ border-bottom: 10px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div>
+ <span id="span1">
+ <span></span>
+ </span>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-010.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-010.xht
new file mode 100644
index 0000000000..65af8204c6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-010.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom applied to element with display list-item</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <meta name="assert" content="The 'padding-bottom' property applies to elements with a display of list-item." />
+ <style type="text/css">
+ body
+ {
+ margin-left: 50px;
+ }
+ div
+ {
+ width: 200px;
+ }
+ #div1
+ {
+ border-bottom: 10px solid blue;
+ display: list-item;
+ padding-bottom: 50px;
+ }
+ div div
+ {
+ border-bottom: 10px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines and there is a marker bullet on the left-hand side of the orange line. (Note the marker bullet does not need to be aligned with either line.)</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-012.xht
new file mode 100644
index 0000000000..11f8d90cd4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-012.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom applied to element with display inline-block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-bottom-applies-to-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property applies to elements with a display of inline-block." />
+ <style type="text/css">
+ div
+ {
+ width: 200px;
+ }
+ #div1
+ {
+ border-bottom: 10px solid blue;
+ display: inline-block;
+ padding-bottom: 50px;
+ }
+ div div
+ {
+ border-bottom: 10px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-013.xht
new file mode 100644
index 0000000000..3399e94851
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-013.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom applied to element with display table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-bottom-applies-to-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property applies to elements with a display of table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ width: 200px;
+ }
+ #table
+ {
+ display: table;
+ padding-bottom: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-bottom: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-014.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-014.xht
new file mode 100644
index 0000000000..a43122ce96
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-014.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom applied to element with display inline-table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-bottom-applies-to-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property applies to elements with a display of inline-table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-bottom: 10px solid blue;
+ width: 200px;
+ }
+ #table
+ {
+ display: inline-table;
+ padding-bottom: 50px;
+ vertical-align: top;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-bottom: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-015.xht
new file mode 100644
index 0000000000..d656b6f885
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-bottom-applies-to-015.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-bottom applied to element with display table-caption</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-23 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-bottom" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-bottom-applies-to-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-bottom' property applies to elements with a display of table-caption." />
+ <style type="text/css">
+ #test
+ {
+ border-bottom: 10px solid blue;
+ display: table-caption;
+ padding-bottom: 50px;
+ width: 200px;
+ }
+ #test div
+ {
+ border-bottom: 10px solid orange;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div></div>
+ </div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-em-inherit-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-em-inherit-001-ref.xht
new file mode 100644
index 0000000000..7496ccc198
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-em-inherit-001-ref.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p
+ {
+ font: 1em/1.25 serif;
+ margin: 1em 0em;
+ }
+
+ div
+ {
+ background-color: green;
+ height: 254px;
+ width: 400px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled<br />
+ green rectangle and no red.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-em-inherit-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-em-inherit-001.xht
new file mode 100644
index 0000000000..9fb9c15a02
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-em-inherit-001.xht
@@ -0,0 +1,101 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Test: inherit applied on padding set with em</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+ <link rel="help" title="8.4 Padding properties" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="help" title="4.3.2 Length" href="http://www.w3.org/TR/CSS21/syndata.html#length-units" />
+ <link rel="help" title="6.2.1 The 'inherit' value" href="http://www.w3.org/TR/CSS21/cascade.html#value-def-inherit" />
+ <link rel="help" href="http://www.w3.org/TR/css-cascade-3/#inherit" />
+ <link rel="help" href="http://www.w3.org/TR/css-cascade-4/#inherit" />
+ <link rel="match" href="padding-em-inherit-001-ref.xht" />
+
+ <meta content="The 'em' unit is equal to the computed value of the 'font-size' property of the element on which it is used. When inherit keyword is used, the property takes the same computed value - a length value in this testcase - as the property for the element's parent." name="assert" />
+ <meta content="image" name="flags" />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p
+ {
+ font: 1em/1.25 serif;
+ margin: 1em 0em;
+ }
+
+ div#grand-parent
+ {
+ font-size: 32px;
+ width: 400px;
+ }
+
+ div#parent
+ {
+ background-color: green;
+ font-size: 24px;
+ padding: 2em 3em 1em 4em; /* 48px 72px 24px 96px */
+ }
+
+ div#child
+ {
+ font-size: 40px;
+ padding: inherit;
+ /*
+ What is inherited is a computed length value:
+ so it is 48px 72px 24px 96px and not 80px 120px 40px 160px
+ */
+ }
+
+ div#abs-pos-overlapping-green
+ {
+ left: 200px;
+ /*
+ 8px (body's margin-left)
+ +
+ 96px (#parent's padding-left)
+ +
+ 96px (#child's padding-left)
+ ==================
+ 200px
+ */
+ position: absolute;
+ top: 168px;
+ }
+
+ /*
+ max(8px, 16px) (margin collapsing between body's margin-top and p's margin-top)
+ +
+ 20px (first line)
+ +
+ 20px (second line)
+ +
+ 16px (p's margin-bottom)
+ +
+ 48px (#parent's padding-top)
+ +
+ 48px (#child's padding-top)
+ ==================
+ 168px
+ */
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled<br />
+ green rectangle and no red.</p>
+
+ <div id="grand-parent">
+ <div id="parent">
+ <div id="child"><img src="support/100x100-red.png" alt="Image download support must be enabled" /></div>
+ </div>
+ </div>
+
+ <div id="abs-pos-overlapping-green"><img src="support/swatch-green.png" width="100" height="100" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-001.xht
new file mode 100644
index 0000000000..c58a7431b2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-001.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using pixels with a minimum minus one value, -1px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-left' property handles a minimum minus one length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -1px;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-002.xht
new file mode 100644
index 0000000000..ba735031c4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-002.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using pixels with a minimum value, 0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a minimum length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: 0px;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-003.xht
new file mode 100644
index 0000000000..eff5e33a47
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-003.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using pixels with a minimum plus one value, 1px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a minimum plus one length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 2px solid red;
+ padding-left: 1px;
+ }
+ div div
+ {
+ border-left: 2px solid black;
+ margin-left: -3px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-004.xht
new file mode 100644
index 0000000000..129a10ae85
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-004.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using pixels with a negative zero value, -0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a negative zero length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -0px;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-005.xht
new file mode 100644
index 0000000000..88172531d9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-005.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using pixels with a positive zero value, +0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a positive zero length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: +0px;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-006.xht
new file mode 100644
index 0000000000..a62189f3a9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-006.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using pixels with a nominal value, 96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 2px solid red;
+ padding-left: 96px;
+ }
+ div div
+ {
+ border-left: 2px solid black;
+ margin-left: -98px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-007.xht
new file mode 100644
index 0000000000..960e34de50
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-007.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using pixels with a nominal value with a plus sign, +96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in pixels with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 2px solid red;
+ padding-left: +96px;
+ }
+ div div
+ {
+ border-left: 2px solid black;
+ margin-left: -98px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-012.xht
new file mode 100644
index 0000000000..4036e5903a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-012.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using points with a minimum minus one value, -1pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-left' property handles a minimum minus one length value in points." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -1pt;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-013.xht
new file mode 100644
index 0000000000..53b4768669
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-013.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using points with a minimum value, 0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a minimum length value in points." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: 0pt;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-015.xht
new file mode 100644
index 0000000000..77cea3a7a4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-015.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using points with a negative zero value, -0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a negative zero length value in points." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -0pt;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-016.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-016.xht
new file mode 100644
index 0000000000..d0f90e41f3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-016.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using points with a positive zero value, +0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a positive zero length value in points." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: +0pt;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-017.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-017.xht
new file mode 100644
index 0000000000..e1a8f03545
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-017.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using points with a nominal value, 72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-019-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in points." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 6pt solid red;
+ padding-left: 72pt;
+ }
+ div div
+ {
+ border-left: 6pt solid black;
+ margin-left: -78pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-018.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-018.xht
new file mode 100644
index 0000000000..88d87d8dff
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-018.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using points with a nominal value with a plus sign, +72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-019-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in points with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 6pt solid red;
+ padding-left: +72pt;
+ }
+ div div
+ {
+ border-left: 6pt solid black;
+ margin-left: -78pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-023.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-023.xht
new file mode 100644
index 0000000000..1fb8cf0f49
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-023.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using picas with a minimum minus one value, -1pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-left' property handles a minimum minus one length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -1pc;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-024.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-024.xht
new file mode 100644
index 0000000000..d6881f43c1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-024.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using picas with a minimum value, 0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a minimum length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: 0pc;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-025.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-025.xht
new file mode 100644
index 0000000000..94a756b6ee
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-025.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using picas with a minimum plus one value, 1pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-031-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a minimum plus one length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 1pc solid red;
+ padding-left: 1pc;
+ }
+ div div
+ {
+ border-left: 1pc solid black;
+ margin-left: -2pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-026.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-026.xht
new file mode 100644
index 0000000000..d93cb18e2d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-026.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using picas with a negative zero value, -0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a negative zero length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -0pc;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-027.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-027.xht
new file mode 100644
index 0000000000..f565cbc737
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-027.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using picas with a positive zero value, +0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a positive zero length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: +0pc;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-028.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-028.xht
new file mode 100644
index 0000000000..c9d7d30bac
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-028.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using picas with a nominal value, 6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-031-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 1pc solid red;
+ padding-left: 6pc;
+ }
+ div div
+ {
+ border-left: 1pc solid black;
+ margin-left: -7pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-029.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-029.xht
new file mode 100644
index 0000000000..bd2b7ac0ca
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-029.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using picas with a nominal value with a plus sign, +6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-031-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in picas with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 1pc solid red;
+ padding-left: +6pc;
+ }
+ div div
+ {
+ border-left: 1pc solid black;
+ margin-left: -7pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-034.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-034.xht
new file mode 100644
index 0000000000..6bbeb73a2f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-034.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using centimeters with a minimum minus one value, -1cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-left' property handles a minimum minus one length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -1cm;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-035.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-035.xht
new file mode 100644
index 0000000000..37741c077d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-035.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using centimeters with a minimum value, 0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a minimum length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: 0cm;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-036-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-036-ref.xht
new file mode 100644
index 0000000000..c00df8f287
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-036-ref.xht
@@ -0,0 +1,16 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Reftest Reference</title>
+ <link rel="author" title="Ms2ger" href="mailto:Ms2ger@gmail.com"/>
+ <style type="text/css">
+ #div1 { height: 50px; width: 1cm; background: green; }
+ #div2 { height: 50px; width: 38px; background: green; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-036.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-036.xht
new file mode 100644
index 0000000000..970fdd1729
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-036.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using centimeters with a minimum plus one value, 1cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-left-036-ref.xht"/>
+ <meta name="assert" content="The 'padding-left' property handles a minimum plus one length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 50px;
+ width: 0;
+ }
+ .parent1
+ {
+ background: red;
+ min-width: 37px
+ }
+ .test1, .test2
+ {
+ padding-left: 1cm;
+ }
+ .test1
+ {
+ background: green;
+ }
+ .test2
+ {
+ background: red;
+ }
+ .child1
+ {
+ background: green;
+ left: -38px;
+ position: relative;
+ width: 38px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div class="parent1">
+ <div class="test1"></div>
+ </div>
+ <div class="test2">
+ <div class="child1"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-037.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-037.xht
new file mode 100644
index 0000000000..ad5349ed7e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-037.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using centimeters with a negative zero value, -0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a negative zero length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -0cm;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-038.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-038.xht
new file mode 100644
index 0000000000..ac882a0ac6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-038.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using centimeters with a positive zero value, +0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a positive zero length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: +0cm;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-039.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-039.xht
new file mode 100644
index 0000000000..28035e9169
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-039.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using centimeters with a nominal value, 2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 2.54cm solid red;
+ padding-left: 2.54cm;
+ }
+ div div
+ {
+ border-left: 2.54cm solid black;
+ margin-left: -5.08cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-040.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-040.xht
new file mode 100644
index 0000000000..415ad13e42
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-040.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using centimeters with a nominal value with a plus sign, +2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in centimeters with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 2.54cm solid red;
+ padding-left: +2.54cm;
+ }
+ div div
+ {
+ border-left: 2.54cm solid black;
+ margin-left: -5.08cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-045.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-045.xht
new file mode 100644
index 0000000000..a894b6c979
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-045.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using millimeters with a minimum minus one value, -1mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-left' property handles a minimum minus one length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -1mm;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-046.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-046.xht
new file mode 100644
index 0000000000..25a10bef01
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-046.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using millimeters with a minimum value, 0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a minimum length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: 0mm;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-047-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-047-ref.xht
new file mode 100644
index 0000000000..c1c81be7a0
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-047-ref.xht
@@ -0,0 +1,16 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Reftest Reference</title>
+ <link rel="author" title="Ms2ger" href="mailto:Ms2ger@gmail.com"/>
+ <style type="text/css">
+ #div1 { height: 50px; width: 1mm; background: green; }
+ #div2 { height: 50px; width: 4px; background: green; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-047.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-047.xht
new file mode 100644
index 0000000000..69856b5d9f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-047.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using millimeters with a minimum plus one value, 1mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-left-047-ref.xht"/>
+ <meta name="assert" content="The 'padding-left' property handles a minimum plus one length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 50px;
+ width: 0;
+ }
+ .parent1
+ {
+ background: red;
+ min-width: 3px
+ }
+ .test1, .test2
+ {
+ padding-left: 1mm;
+ }
+ .test1
+ {
+ background: green;
+ }
+ .test2
+ {
+ background: red;
+ }
+ .child1
+ {
+ background: green;
+ left: -4px;
+ position: relative;
+ width: 4px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div class="parent1">
+ <div class="test1"></div>
+ </div>
+ <div class="test2">
+ <div class="child1"></div>
+ </div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-048.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-048.xht
new file mode 100644
index 0000000000..7790a94473
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-048.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using millimeters with a negative zero value, -0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a negative zero length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -0mm;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-049.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-049.xht
new file mode 100644
index 0000000000..01c1ef3de1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-049.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using millimeters with a positive zero value, +0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a positive zero length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: +0mm;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-050.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-050.xht
new file mode 100644
index 0000000000..9165ac9193
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-050.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using millimeters with a nominal value, 25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 25.4mm solid red;
+ padding-left: 25.4mm;
+ }
+ div div
+ {
+ border-left: 25.4mm solid black;
+ margin-left: -50.8mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-051.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-051.xht
new file mode 100644
index 0000000000..96ea400a25
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-051.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using millimeters with a nominal value with a plus sign, +25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in millimeters with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 25.4mm solid red;
+ padding-left: +25.4mm;
+ }
+ div div
+ {
+ border-left: 25.4mm solid black;
+ margin-left: -50.8mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-056.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-056.xht
new file mode 100644
index 0000000000..05bd642379
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-056.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using inches with a minimum minus one value, -1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-left' property handles a minimum minus one length value in inches." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -1in;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-057.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-057.xht
new file mode 100644
index 0000000000..8b14887c55
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-057.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using inches with a minimum value, 0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a minimum length value in inches." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: 0in;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-058.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-058.xht
new file mode 100644
index 0000000000..0304c515cf
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-058.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using inches with a minimum plus one value, 1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a minimum plus one length value in inches." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 1in solid red;
+ padding-left: 1in;
+ }
+ div div
+ {
+ border-left: 1in solid black;
+ margin-left: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-059.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-059.xht
new file mode 100644
index 0000000000..921bc03bb1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-059.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using inches with a negative zero value, -0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a negative zero length value in inches." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -0in;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-060.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-060.xht
new file mode 100644
index 0000000000..e052ad0917
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-060.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using inches with a positive zero value, +0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a positive zero length value in inches." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: +0in;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-061.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-061.xht
new file mode 100644
index 0000000000..edda6582f7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-061.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using inches with a nominal value, 3in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in inches." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 1in solid red;
+ padding-left: 3in;
+ }
+ div div
+ {
+ border-left: 1in solid black;
+ margin-left: -4in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-062.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-062.xht
new file mode 100644
index 0000000000..b3579ac5cf
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-062.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using inches with a nominal value with a plus sign, +3in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in inches with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 1in solid red;
+ padding-left: +3in;
+ }
+ div div
+ {
+ border-left: 1in solid black;
+ margin-left: -4in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-067.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-067.xht
new file mode 100644
index 0000000000..5e380aba85
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-067.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using 'em' units with a minimum minus one value, -1em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem invalid" />
+ <meta name="assert" content="The 'padding-left' property handles a minimum minus one length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -1em;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-068.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-068.xht
new file mode 100644
index 0000000000..966b43e0b5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-068.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using 'em' units with a minimum value, 0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-left' property handles a minimum length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: 0em;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-069.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-069.xht
new file mode 100644
index 0000000000..5bed2599f3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-069.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using 'em' units with a minimum plus one value, 1em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-left' property handles a minimum plus one length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 1em solid red;
+ padding-left: 1em;
+ }
+ div div
+ {
+ border-left: 1em solid black;
+ margin-left: -2em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-070.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-070.xht
new file mode 100644
index 0000000000..0b35b81892
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-070.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using 'em' units with a negative zero value, -0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-left' property handles a negative zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -0em;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-071.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-071.xht
new file mode 100644
index 0000000000..7305e86529
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-071.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using 'em' units with a positive zero value, +0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-left' property handles a positive zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: +0em;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-072.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-072.xht
new file mode 100644
index 0000000000..0868bc83e4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-072.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using 'em' units with a nominal value, 6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 1em solid red;
+ padding-left: 6em;
+ }
+ div div
+ {
+ border-left: 1em solid black;
+ margin-left: -7em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-073.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-073.xht
new file mode 100644
index 0000000000..d25a74ca38
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-073.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using 'em' units with a nominal value with a plus sign, +6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in 'em' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 1em solid red;
+ padding-left: +6em;
+ }
+ div div
+ {
+ border-left: 1em solid black;
+ margin-left: -7em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-078.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-078.xht
new file mode 100644
index 0000000000..72865436d3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-078.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using 'ex' units with a minimum minus one value, -1ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem invalid" />
+ <meta name="assert" content="The 'padding-left' property handles a minimum minus one length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -1ex;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-079.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-079.xht
new file mode 100644
index 0000000000..fcba695cfe
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-079.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using 'ex' units with a minimum value, 0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-left' property handles a minimum length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: 0ex;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-080.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-080.xht
new file mode 100644
index 0000000000..1b8714b9ea
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-080.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using 'ex' units with a minimum plus one value, 1ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-left' property handles a minimum plus one length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 1ex solid red;
+ padding-left: 1ex;
+ }
+ div div
+ {
+ border-left: 1ex solid black;
+ margin-left: -2ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-081.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-081.xht
new file mode 100644
index 0000000000..3155c5d594
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-081.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using 'ex' units with a negative zero value, -0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-left' property handles a negative zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -0ex;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-082.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-082.xht
new file mode 100644
index 0000000000..c4f5bdc300
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-082.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using 'ex' units with a positive zero value, +0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-left' property handles a positive zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: +0ex;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-083.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-083.xht
new file mode 100644
index 0000000000..6cdd476139
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-083.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using 'ex' units with a nominal value, 6ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 1ex solid red;
+ padding-left: 6ex;
+ }
+ div div
+ {
+ border-left: 1ex solid black;
+ margin-left: -7ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-084.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-084.xht
new file mode 100644
index 0000000000..99a170fbbc
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-084.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using 'ex' units with a nominal value with a plus sign, +6ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in 'ex' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 1ex solid red;
+ padding-left: +6ex;
+ }
+ div div
+ {
+ border-left: 1ex solid black;
+ margin-left: -7ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-089.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-089.xht
new file mode 100644
index 0000000000..bfd2cd342b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-089.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using percentage with a minimum minus one value, -1%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-left' property handles a minimum minus one length value in percentage." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -1%;
+ }
+ #div2
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-090.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-090.xht
new file mode 100644
index 0000000000..d03c28eb4a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-090.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using percentage with a minimum value, 0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a minimum length value in percentage." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: 0%;
+ }
+ #div2
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-091-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-091-ref.xht
new file mode 100644
index 0000000000..66d45db297
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-091-ref.xht
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 10px;
+ height: 1in;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-091.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-091.xht
new file mode 100644
index 0000000000..9d648a0759
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-091.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using percentage with a minimum plus one value, 1%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-left-091-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a minimum plus one length value in percentage." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ width: 200px;
+ }
+ #div1
+ {
+ border-left: 10px solid red;
+ padding-left: 1%;
+ }
+ #div2
+ {
+ border-left: 10px solid black;
+ margin-left: -12px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-092.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-092.xht
new file mode 100644
index 0000000000..74df9ddf18
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-092.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using percentage with a negative zero value, -0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a negative zero length value in percentage." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -0%;
+ }
+ #div2
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-093.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-093.xht
new file mode 100644
index 0000000000..217b738c00
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-093.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using percentage with a positive zero value, +0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a positive zero length value in percentage." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: +0%;
+ }
+ #div2
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-094.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-094.xht
new file mode 100644
index 0000000000..224ed099e6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-094.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using percentage with a nominal value, 50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in percentage." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ width: 2in;
+ }
+ #div1
+ {
+ border-left: 1in solid red;
+ padding-left: 50%;
+ }
+ #div2
+ {
+ border-left: 1in solid black;
+ margin-left: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-095.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-095.xht
new file mode 100644
index 0000000000..334976eece
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-095.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using percentage with a nominal value with a plus sign, +50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a nominal length value in percentage with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ width: 2in;
+ }
+ #div1
+ {
+ border-left: 1in solid red;
+ padding-left: +50%;
+ }
+ #div2
+ {
+ border-left: 1in solid black;
+ margin-left: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-100.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-100.xht
new file mode 100644
index 0000000000..8dde053b40
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-100.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left with a negative zero value and no units, -0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a negative zero length value with no units." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: -0;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-101.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-101.xht
new file mode 100644
index 0000000000..db207e702e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-101.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left with a zero value and no units, 0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a zero length value with no units." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: 0;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-102.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-102.xht
new file mode 100644
index 0000000000..33f8e5461b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-102.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left with a positive zero value and no units, +0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles a positive zero length value with no units." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: +0;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-103-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-103-ref.xht
new file mode 100644
index 0000000000..b974070768
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-103-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-right: black solid 1in;
+ height: 1in;
+ width: 1in;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-103.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-103.xht
new file mode 100644
index 0000000000..96e89edb8b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-103.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left using the 'inherit' value</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-left-103-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property handles the 'inherit' value." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ padding-left: 1in;
+ }
+ #div1
+ {
+ border-left: 1in solid red;
+ padding-left: inherit;
+ }
+ #div2
+ {
+ border-left: 1in solid black;
+ margin-left: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-001.xht
new file mode 100644
index 0000000000..5d80410226
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-001.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left applied to element with display table-row-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property does not apply to elements with a display of table-row-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #test
+ {
+ display: table-row-group;
+ padding-left: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-left: 10px solid orange;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-002.xht
new file mode 100644
index 0000000000..186de1bb57
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-002.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left applied to element with display table-header-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property does not apply to elements with a display of table-header-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #test
+ {
+ display: table-header-group;
+ padding-left: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-left: 10px solid orange;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-003.xht
new file mode 100644
index 0000000000..08b739a462
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-003.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left applied to element with display table-footer-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property does not apply to elements with a display of table-footer-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #test
+ {
+ display: table-footer-group;
+ padding-left: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-left: 10px solid orange;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-004.xht
new file mode 100644
index 0000000000..96bd842c16
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-004.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left applied to element with display table-row</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property does not apply to elements with a display of table-row." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ padding-left: 50px;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-left: 10px solid orange;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-005.xht
new file mode 100644
index 0000000000..f05c4f5132
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-005.xht
@@ -0,0 +1,54 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left applied to element with display table-column-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property does not apply to elements with a display of table-column-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #test
+ {
+ display: table-column-group;
+ padding-left: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-left: 10px solid orange;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-006.xht
new file mode 100644
index 0000000000..6a04c15549
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-006.xht
@@ -0,0 +1,54 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left applied to element with display table-column</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property does not apply to elements with a display of table-column." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #test
+ {
+ display: table-column;
+ padding-left: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-left: 10px solid orange;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-007.xht
new file mode 100644
index 0000000000..6110016358
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-007.xht
@@ -0,0 +1,44 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left applied to element with display table-cell</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property applies to elements with a display of table-cell." />
+ <style type="text/css">
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-left: 10px solid blue;
+ display: table-cell;
+ padding-left: 50px;
+ }
+ #cell div
+ {
+ border-left: 10px solid orange;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-008-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-008-ref.xht
new file mode 100644
index 0000000000..3214099d4a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-008-ref.xht
@@ -0,0 +1,15 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Reftest Reference</title>
+ <link rel="author" title="Ms2ger" href="mailto:Ms2ger@gmail.com"/>
+ <style type="text/css">
+ span { border-left: 5px solid blue; }
+ span span { margin-left: 50px; border-left: 5px solid orange; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div><span><span></span></span>Filler Text</div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-008.xht
new file mode 100644
index 0000000000..f4f10b1670
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-008.xht
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left applied to element with display inline</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-left-applies-to-008-ref.xht"/>
+ <meta name="assert" content="The 'padding-left' property applies to elements with a display of inline." />
+ <style type="text/css">
+ div
+ {
+ display: inline;
+ }
+ #div1
+ {
+ border-left: 5px solid blue;
+ padding-left: 50px;
+ }
+ div div
+ {
+ border-left: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="div1">
+ <div>Filler Text</div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-009.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-009.xht
new file mode 100644
index 0000000000..0796980dd8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-009.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left applied to element with display block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property applies to elements with a display of block." />
+ <style type="text/css">
+ span
+ {
+ display: block;
+ }
+ #span1
+ {
+ border-left: 10px solid blue;
+ padding-left: 50px;
+ }
+ span span
+ {
+ border-left: 10px solid orange;
+ height: 200px;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div>
+ <span id="span1">
+ <span></span>
+ </span>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-010-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-010-ref.xht
new file mode 100644
index 0000000000..95d45f8844
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-010-ref.xht
@@ -0,0 +1,16 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Reftest Reference</title>
+ <link rel="author" title="Ms2ger" href="mailto:Ms2ger@gmail.com"/>
+ <style type="text/css">
+ body { margin-left: 50px; }
+ #div1 { display: list-item; height: 200px; width: 200px; }
+ div div { width: 50px; height: 200px; border-left: 10px solid blue; border-right: 10px solid orange; }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines and there is a marker bullet on the left-hand side of the blue line.</p>
+ <div id="div1"><div></div></div>
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-010.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-010.xht
new file mode 100644
index 0000000000..efe778baeb
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-010.xht
@@ -0,0 +1,39 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left applied to element with display list-item</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-left-applies-to-010-ref.xht"/>
+ <meta name="assert" content="The 'padding-left' property applies to elements with a display of list-item." />
+ <style type="text/css">
+ body
+ {
+ margin-left: 50px;
+ }
+ div
+ {
+ height: 200px;
+ width: 200px;
+ }
+ #div1
+ {
+ border-left: 10px solid blue;
+ display: list-item;
+ padding-left: 50px;
+ }
+ div div
+ {
+ border-left: 10px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines and there is a marker bullet on the left-hand side of the blue line.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-012.xht
new file mode 100644
index 0000000000..7907e88c73
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-012.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left applied to element with display inline-block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property applies to elements with a display of inline-block." />
+ <style type="text/css">
+ div
+ {
+ height: 200px;
+ display: inline-block;
+ }
+ #div1
+ {
+ border-left: 10px solid blue;
+ padding-left: 50px;
+ width: 200px;
+ }
+ div div
+ {
+ border-left: 10px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-013.xht
new file mode 100644
index 0000000000..473175b3ec
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-013.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left applied to element with display table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property applies to elements with a display of table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #table
+ {
+ display: table;
+ padding-left: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-left: 10px solid orange;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-014.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-014.xht
new file mode 100644
index 0000000000..8c5ae43e1c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-014.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left applied to element with display inline-table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property applies to elements with a display of inline-table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-left: 10px solid blue;
+ }
+ #table
+ {
+ display: inline-table;
+ padding-left: 50px;
+ vertical-align: top;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-left: 10px solid orange;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-015.xht
new file mode 100644
index 0000000000..fa8e8919ad
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-left-applies-to-015.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-left applied to element with display table-caption</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-left" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding-left' property applies to elements with a display of table-caption." />
+ <style type="text/css">
+ #test
+ {
+ border-left: 10px solid blue;
+ display: table-caption;
+ padding-left: 50px;
+ }
+ #test div
+ {
+ border-left: 10px solid orange;
+ height: 200px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="table">
+ <div id="test">
+ <div></div>
+ </div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-percentage-inherit-001-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-percentage-inherit-001-ref.xht
new file mode 100644
index 0000000000..3d9fd5c2c0
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-percentage-inherit-001-ref.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p
+ {
+ font: 1em/1.25 serif;
+ margin: 1em 0em;
+ }
+
+ div
+ {
+ background-color: green;
+ height: 270px;
+ width: 270px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled<br />
+ green square and no red.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-percentage-inherit-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-percentage-inherit-001.xht
new file mode 100644
index 0000000000..d3e9c8b428
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-percentage-inherit-001.xht
@@ -0,0 +1,96 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Test: padding - inherit applied on padding percentage</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+ <link rel="help" title="8.4 Padding properties" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="help" title="6.2.1 The 'inherit' value" href="http://www.w3.org/TR/CSS21/cascade.html#value-def-inherit" />
+ <link rel="help" href="http://www.w3.org/TR/css-cascade-3/#inherit" />
+ <link rel="help" href="http://www.w3.org/TR/css-cascade-4/#inherit" />
+ <link rel="match" href="padding-percentage-inherit-001-ref.xht" />
+
+ <meta content="A padding percentage is calculated with respect to the width of the generated box's containing block. When inherit keyword is used, the property takes the same computed value - a percentage value in this testcase - as the property for the element's parent." name="assert" />
+ <meta content="image" name="flags" />
+
+ <style type="text/css"><![CDATA[
+ body {margin: 8px;}
+
+ p
+ {
+ font: 1em/1.25 serif;
+ margin: 1em 0em;
+ }
+
+ div#grand-parent {width: 300px;}
+
+ div#parent
+ {
+ background-color: green;
+ height: 150px;
+ padding: 20%; /* 20% of 300px == 60px; */
+ width: 150px;
+ }
+
+ div#child
+ {
+ padding: inherit;
+ /*
+ computes to 20% which is then applied
+ on #child's containing block width: 20% of 150px == 30px
+ */
+ }
+
+ div#abs-pos-overlapping-green
+ {
+ left: 98px;
+ /*
+ 8px (body's margin-left)
+ +
+ 60px (#parent's padding-left)
+ +
+ 30px (#child's padding-left)
+ ==================
+ 98px
+ */
+ position: absolute;
+ top: 162px;
+ }
+
+ /*
+ max(8px, 16px) (margin collapsing between body's margin-top and p's margin-top)
+ +
+ 20px (first line)
+ +
+ 20px (second line)
+ +
+ 16px (p's margin-bottom)
+ +
+ 60px (#parent's padding-top)
+ +
+ 30px (#child's padding-top)
+ ==================
+ 162px
+ */
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is a filled<br />
+ green square and no red.</p>
+
+ <div id="grand-parent">
+ <div id="parent">
+ <div id="child"><img src="support/100x100-red.png" alt="Image download support must be enabled" /></div>
+ </div>
+ </div>
+
+ <div id="abs-pos-overlapping-green"><img src="support/swatch-green.png" width="100" height="100" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-percentage-undefined-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-percentage-undefined-001.xht
new file mode 100644
index 0000000000..60a59fe5a0
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-percentage-undefined-001.xht
@@ -0,0 +1,26 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding with percentage determined by containing block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <meta name="assert" content="Potential circular reference cannot cause the user agent to crash or hang." />
+ <style type="text/css">
+ #div1
+ {
+ float: left;
+ border: 1px solid blue;
+ }
+ div div
+ {
+ padding: 50%;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if the words "Filler Text" appear below.</p>
+ <div id="div1">
+ <div>Filler Text</div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-001.xht
new file mode 100644
index 0000000000..025d5c0d46
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-001.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using pixels with a minimum minus one value, -1px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-right' property handles a minimum minus one length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -1px;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-002.xht
new file mode 100644
index 0000000000..efeebd7aa5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-002.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using pixels with a minimum value, 0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a minimum length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: 0px;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-003-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-003-ref.xht
new file mode 100644
index 0000000000..756ecf3984
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-003-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 3px;
+ height: 96px;
+ margin-left: 1px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-003.xht
new file mode 100644
index 0000000000..74ccc7a81e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-003.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using pixels with a minimum plus one value, 1px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-003-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a minimum plus one length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 3px solid red;
+ padding-right: 1px;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 3px solid black;
+ margin-right: -4px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-004.xht
new file mode 100644
index 0000000000..b9151d8d74
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-004.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using pixels with a negative zero value, -0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a negative zero length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -0px;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-005.xht
new file mode 100644
index 0000000000..6acf26bafc
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-005.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using pixels with a positive zero value, +0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a positive zero length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: +0px;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-006-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-006-ref.xht
new file mode 100644
index 0000000000..2db14a83b0
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-006-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 3px;
+ height: 96px;
+ margin-left: 96px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-006.xht
new file mode 100644
index 0000000000..1a4ea7a47f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-006.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using pixels with a nominal value, 96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-006-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in pixels." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 3px solid red;
+ padding-right: 96px;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 3px solid black;
+ margin-right: -99px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-007.xht
new file mode 100644
index 0000000000..4ddb96f75f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-007.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using pixels with a nominal value with a plus sign, +96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-006-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in pixels with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 3px solid red;
+ padding-right: +96px;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 3px solid black;
+ margin-right: -99px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-012.xht
new file mode 100644
index 0000000000..ae5920663e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-012.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using points with a minimum minus one value, -1pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-right' property handles a minimum minus one length value in points." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -1pt;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-013.xht
new file mode 100644
index 0000000000..f04803da57
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-013.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using points with a minimum value, 0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a minimum length value in points." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: 0pt;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-015.xht
new file mode 100644
index 0000000000..85091aa7b4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-015.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using points with a negative zero value, -0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a negative zero length value in points." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -0pt;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-016.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-016.xht
new file mode 100644
index 0000000000..273d5b1292
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-016.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using points with a positive zero value, +0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a positive zero length value in points." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: +0pt;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-017-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-017-ref.xht
new file mode 100644
index 0000000000..64c7d3f754
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-017-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 8px;
+ height: 96px;
+ margin-left: 96px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-017.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-017.xht
new file mode 100644
index 0000000000..714e5fff5d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-017.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using points with a nominal value, 72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-017-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in points." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 6pt solid red;
+ padding-right: 72pt;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 6pt solid black;
+ margin-right: -78pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-018.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-018.xht
new file mode 100644
index 0000000000..918918cd4d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-018.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using points with a nominal value with a plus sign, +72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-017-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in points with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 6pt solid red;
+ padding-right: +72pt;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 6pt solid black;
+ margin-right: -78pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-023.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-023.xht
new file mode 100644
index 0000000000..e363aabce7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-023.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using picas with a minimum minus one value, -1pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-right' property handles a minimum minus one length value in picas." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -1pc;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-024.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-024.xht
new file mode 100644
index 0000000000..5e4777d9b5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-024.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using picas with a minimum value, 0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a minimum length value in picas." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: 0pc;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-025-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-025-ref.xht
new file mode 100644
index 0000000000..992b1b086d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-025-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 16px;
+ height: 96px;
+ margin-left: 16px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-025.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-025.xht
new file mode 100644
index 0000000000..1c89240d1e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-025.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using picas with a minimum plus one value, 1pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-025-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a minimum plus one length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 1pc solid red;
+ padding-right: 1pc;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 1pc solid black;
+ margin-right: -2pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-026.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-026.xht
new file mode 100644
index 0000000000..a1ef19b94e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-026.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using picas with a negative zero value, -0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a negative zero length value in picas." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -0pc;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-027.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-027.xht
new file mode 100644
index 0000000000..7e706a791d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-027.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using picas with a positive zero value, +0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a positive zero length value in picas." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: +0pc;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-028-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-028-ref.xht
new file mode 100644
index 0000000000..a5f1d3231e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-028-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 16px;
+ height: 96px;
+ margin-left: 96px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-028.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-028.xht
new file mode 100644
index 0000000000..6589ec1f2a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-028.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using picas with a nominal value, 6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-028-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in picas." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 1pc solid red;
+ padding-right: 6pc;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 1pc solid black;
+ margin-right: -7pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-029.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-029.xht
new file mode 100644
index 0000000000..4acb9cdb23
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-029.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using picas with a nominal value with a plus sign, +6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-028-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in picas with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 1pc solid red;
+ padding-right: +6pc;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 1pc solid black;
+ margin-right: -7pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-034.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-034.xht
new file mode 100644
index 0000000000..71b2b2a8b8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-034.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using centimeters with a minimum minus one value, -1cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-right' property handles a minimum minus one length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -1cm;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-035.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-035.xht
new file mode 100644
index 0000000000..9945db3764
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-035.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using centimeters with a minimum value, 0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a minimum length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: 0cm;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-036.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-036.xht
new file mode 100644
index 0000000000..261a88b167
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-036.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using centimeters with a minimum plus one value, 1cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-left-036-ref.xht"/>
+ <meta name="assert" content="The 'padding-right' property handles a minimum plus one length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 50px;
+ width: 0;
+ }
+ .parent1
+ {
+ background: red;
+ min-width: 37px
+ }
+ .test1, .test2
+ {
+ padding-right: 1cm;
+ }
+ .test1
+ {
+ background: green;
+ }
+ .test2
+ {
+ background: red;
+ }
+ .child1
+ {
+ background: green;
+ position: relative;
+ width: 38px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div class="parent1">
+ <div class="test1"></div>
+ </div>
+ <div class="test2">
+ <div class="child1"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-037.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-037.xht
new file mode 100644
index 0000000000..417fff70d2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-037.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using centimeters with a negative zero value, -0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a negative zero length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -0cm;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-038.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-038.xht
new file mode 100644
index 0000000000..f7b50180f8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-038.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using centimeters with a positive zero value, +0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a positive zero length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: +0cm;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-039-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-039-ref.xht
new file mode 100644
index 0000000000..41ebaa892b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-039-ref.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ background-color: black;
+ height: 96px;
+ margin-left: 96px;
+ width: 96px;
+ }
+
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html>
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-039.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-039.xht
new file mode 100644
index 0000000000..19829bf773
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-039.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using centimeters with a nominal value, 2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-039-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 2.54cm solid red;
+ padding-right: 2.54cm;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 2.54cm solid black;
+ margin-right: -5.08cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-040.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-040.xht
new file mode 100644
index 0000000000..9118bd8b16
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-040.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using centimeters with a nominal value with a plus sign, +2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-039-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in centimeters with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 2.54cm solid red;
+ padding-right: +2.54cm;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 2.54cm solid black;
+ margin-right: -5.08cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-045.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-045.xht
new file mode 100644
index 0000000000..b1a1207a71
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-045.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using millimeters with a minimum minus one value, -1mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-right' property handles a minimum minus one length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -1mm;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-046.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-046.xht
new file mode 100644
index 0000000000..a52902e253
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-046.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using millimeters with a minimum value, 0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a minimum length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: 0mm;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-047.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-047.xht
new file mode 100644
index 0000000000..29d619a967
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-047.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using millimeters with a minimum plus one value, 1mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-left-047-ref.xht"/>
+ <meta name="assert" content="The 'padding-right' property handles a minimum plus one length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 50px;
+ width: 0;
+ }
+ .parent1
+ {
+ background: red;
+ min-width: 3px
+ }
+ .test1, .test2
+ {
+ padding-right: 1mm;
+ }
+ .test1
+ {
+ background: green;
+ }
+ .test2
+ {
+ background: red;
+ }
+ .child1
+ {
+ background: green;
+ position: relative;
+ width: 4px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div class="parent1">
+ <div class="test1"></div>
+ </div>
+ <div class="test2">
+ <div class="child1"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-048.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-048.xht
new file mode 100644
index 0000000000..b97559adda
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-048.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using millimeters with a negative zero value, -0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a negative zero length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -0mm;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-049.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-049.xht
new file mode 100644
index 0000000000..9d59f7c011
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-049.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using millimeters with a positive zero value, +0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a positive zero length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: +0mm;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-050.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-050.xht
new file mode 100644
index 0000000000..ec2695a287
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-050.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using millimeters with a nominal value, 25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-039-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 25.4mm solid red;
+ padding-right: 25.4mm;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 25.4mm solid black;
+ margin-right: -50.8mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-051.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-051.xht
new file mode 100644
index 0000000000..4ac8432e8a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-051.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using millimeters with a nominal value with a plus sign, +25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-039-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in millimeters with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 25.4mm solid red;
+ padding-right: +25.4mm;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 25.4mm solid black;
+ margin-right: -50.8mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-056.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-056.xht
new file mode 100644
index 0000000000..0b62f98361
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-056.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using inches with a minimum minus one value, -1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-right' property handles a minimum minus one length value in inches." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -1in;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-057.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-057.xht
new file mode 100644
index 0000000000..1b843dc656
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-057.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using inches with a minimum value, 0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a minimum length value in inches." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: 0in;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-058.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-058.xht
new file mode 100644
index 0000000000..be66ead114
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-058.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using inches with a minimum plus one value, 1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-039-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a minimum plus one length value in inches." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 1in solid red;
+ padding-right: 1in;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 1in solid black;
+ margin-right: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-059.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-059.xht
new file mode 100644
index 0000000000..7114385f8e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-059.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using inches with a negative zero value, -0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a negative zero length value in inches." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -0in;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-060.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-060.xht
new file mode 100644
index 0000000000..497611c00a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-060.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using inches with a positive zero value, +0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a positive zero length value in inches." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: +0in;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-061-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-061-ref.xht
new file mode 100644
index 0000000000..ac636e20f0
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-061-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 96px;
+ height: 96px;
+ margin-left: 288px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-061.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-061.xht
new file mode 100644
index 0000000000..093366f176
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-061.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using inches with a nominal value, 3in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-061-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in inches." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 0;
+ }
+ #div1
+ {
+ border-right: 1in solid red;
+ padding-right: 3in;
+ }
+ div div
+ {
+ border-right: 1in solid black;
+ margin-right: -4in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-062.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-062.xht
new file mode 100644
index 0000000000..4b11f6006c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-062.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using inches with a nominal value with a plus sign, +3in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-061-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in inches with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ direction: rtl;
+ height: 1in;
+ width: 0;
+ }
+ #div1
+ {
+ border-right: 1in solid red;
+ padding-right: +3in;
+ }
+ div div
+ {
+ border-right: 1in solid black;
+ margin-right: -4in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-067.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-067.xht
new file mode 100644
index 0000000000..cfe704b10a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-067.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using 'em' units with a minimum minus one value, -1em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem invalid" />
+ <meta name="assert" content="The 'padding-right' property handles a minimum minus one length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -1em;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-068.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-068.xht
new file mode 100644
index 0000000000..6b2ed505f9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-068.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using 'em' units with a minimum value, 0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-right' property handles a minimum length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: 0em;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-069-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-069-ref.xht
new file mode 100644
index 0000000000..ef79648b85
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-069-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 20px;
+ height: 96px;
+ margin-left: 20px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-069.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-069.xht
new file mode 100644
index 0000000000..75348b29b7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-069.xht
@@ -0,0 +1,39 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using 'em' units with a minimum plus one value, 1em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-069-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-right' property handles a minimum plus one length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 1em solid red;
+ padding-right: 1em;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 1em solid black;
+ margin-right: -2em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-070.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-070.xht
new file mode 100644
index 0000000000..326e385e46
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-070.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using 'em' units with a negative zero value, -0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-right' property handles a negative zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -0em;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-071.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-071.xht
new file mode 100644
index 0000000000..f5bc69939b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-071.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using 'em' units with a positive zero value, +0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-right' property handles a positive zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: +0em;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-072-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-072-ref.xht
new file mode 100644
index 0000000000..fa4b1b0175
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-072-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 20px;
+ height: 96px;
+ margin-left: 120px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-072.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-072.xht
new file mode 100644
index 0000000000..f8a921be6d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-072.xht
@@ -0,0 +1,39 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using 'em' units with a nominal value, 6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-072-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 1em solid red;
+ padding-right: 6em;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 1em solid black;
+ margin-right: -7em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-073.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-073.xht
new file mode 100644
index 0000000000..e8af303076
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-073.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using 'em' units with a nominal value with a plus sign, +6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-072-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in 'em' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ direction: rtl;
+ height: 1in;
+ width: 0;
+ }
+ #div1
+ {
+ border-right: 1em solid red;
+ padding-right: +6em;
+ }
+ div div
+ {
+ border-right: 1em solid black;
+ margin-right: -7em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-078.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-078.xht
new file mode 100644
index 0000000000..d230bb5110
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-078.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using 'ex' units with a minimum minus one value, -1ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem invalid" />
+ <meta name="assert" content="The 'padding-right' property handles a minimum minus one length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -1ex;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-079.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-079.xht
new file mode 100644
index 0000000000..243440cbce
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-079.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using 'ex' units with a minimum value, 0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-right' property handles a minimum length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: 0ex;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-080-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-080-ref.xht
new file mode 100644
index 0000000000..9797a6337c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-080-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 32px;
+ height: 96px;
+ margin-left: 16px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-080.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-080.xht
new file mode 100644
index 0000000000..115fb36776
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-080.xht
@@ -0,0 +1,39 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using 'ex' units with a minimum plus one value, 1ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-080-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-right' property handles a minimum plus one length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 2ex solid red;
+ padding-right: 1ex;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 2ex solid black;
+ margin-right: -3ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-081.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-081.xht
new file mode 100644
index 0000000000..3ba91a9d59
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-081.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using 'ex' units with a negative zero value, -0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-right' property handles a negative zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -0ex;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-082.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-082.xht
new file mode 100644
index 0000000000..cd12960a10
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-082.xht
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using 'ex' units with a positive zero value, +0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-right' property handles a positive zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: +0ex;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-083-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-083-ref.xht
new file mode 100644
index 0000000000..e304ea4f9d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-083-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 32px;
+ height: 96px;
+ margin-left: 96px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-083.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-083.xht
new file mode 100644
index 0000000000..4780496cb7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-083.xht
@@ -0,0 +1,39 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using 'ex' units with a nominal value, 6ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-083-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 2ex solid red;
+ padding-right: 6ex;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 2ex solid black;
+ margin-right: -8ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-084.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-084.xht
new file mode 100644
index 0000000000..9f3500936c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-084.xht
@@ -0,0 +1,39 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using 'ex' units with a nominal value with a plus sign, +6ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-083-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in 'ex' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px Ahem;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 2ex solid red;
+ padding-right: +6ex;
+ width: 0;
+ }
+ div div
+ {
+ border-right: 2ex solid black;
+ margin-right: -8ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-089-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-089-ref.xht
new file mode 100644
index 0000000000..c98d9eb7f5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-089-ref.xht
@@ -0,0 +1,32 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: orange solid 5px;
+ border-right: blue solid 5px;
+ height: 96px;
+ margin-left: 86px;
+ width: 0px;
+ }
+
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-089.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-089.xht
new file mode 100644
index 0000000000..cbffc2bb26
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-089.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using percentage with a minimum minus one value, -1%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-089-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-right' property handles a minimum minus one length value in percentage." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid blue;
+ padding-right: -1%;
+ }
+ #div2
+ {
+ border-right: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-090.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-090.xht
new file mode 100644
index 0000000000..1f453485f6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-090.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using percentage with a minimum value, 0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-089-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a minimum length value in percentage." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid blue;
+ padding-right: 0%;
+ }
+ #div2
+ {
+ border-right: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-091-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-091-ref.xht
new file mode 100644
index 0000000000..ab8916422b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-091-ref.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-left: black solid 10px;
+ height: 96px;
+ margin-left: 190px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-091.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-091.xht
new file mode 100644
index 0000000000..5e28cb56d3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-091.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using percentage with a minimum plus one value, 1%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-091-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a minimum plus one length value in percentage." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ width: 200px;
+ }
+ #div1
+ {
+ border-right: 10px solid red;
+ padding-right: 1%;
+ }
+ #div2
+ {
+ border-right: 10px solid black;
+ margin-right: -12px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-092.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-092.xht
new file mode 100644
index 0000000000..be0b43979f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-092.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using percentage with a negative zero value, -0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-089-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a negative zero length value in percentage." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid blue;
+ padding-right: -0%;
+ }
+ #div2
+ {
+ border-right: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-093.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-093.xht
new file mode 100644
index 0000000000..8c7ecc744d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-093.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using percentage with a positive zero value, +0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-089-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a positive zero length value in percentage." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid blue;
+ padding-right: +0%;
+ }
+ #div2
+ {
+ border-right: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-094.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-094.xht
new file mode 100644
index 0000000000..8f11b4a27b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-094.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using percentage with a nominal value, 50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-039-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in percentage." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ width: 2in;
+ }
+ #div1
+ {
+ border-right: 1in solid red;
+ padding-right: 50%;
+ }
+ #div2
+ {
+ border-right: 1in solid black;
+ margin-right: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-095.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-095.xht
new file mode 100644
index 0000000000..334fb01454
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-095.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using percentage with a nominal value with a plus sign, +50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-039-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a nominal length value in percentage with a plus sign." />
+ <style type="text/css">
+ div
+ {
+ height: 1in;
+ }
+ #wrapper
+ {
+ width: 2in;
+ }
+ #div1
+ {
+ border-right: 1in solid red;
+ padding-right: +50%;
+ }
+ #div2
+ {
+ border-right: 1in solid black;
+ margin-right: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-100.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-100.xht
new file mode 100644
index 0000000000..6b6cf5f57b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-100.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right with a negative zero value and no units, -0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a negative zero length value with no units." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: -0;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-101.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-101.xht
new file mode 100644
index 0000000000..646712c581
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-101.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right with a zero value and no units, 0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a zero length value with no units." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: 0;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-102.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-102.xht
new file mode 100644
index 0000000000..5f49916b8e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-102.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right with a positive zero value and no units, +0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-004-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles a positive zero length value with no units." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ height: 1in;
+ }
+ #div1
+ {
+ border-right: 5px solid orange;
+ padding-right: +0;
+ }
+ div div
+ {
+ border-right: 5px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-103.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-103.xht
new file mode 100644
index 0000000000..e334a23c36
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-103.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right using the 'inherit' value</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-right-017-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property handles the 'inherit' value." />
+ <style type="text/css">
+ div
+ {
+ height: 96px;
+ }
+ #wrapper
+ {
+ padding-right: 96px;
+ width: 50px;
+ }
+ #div1
+ {
+ border-right: 8px solid red;
+ padding-right: inherit;
+ }
+ #div2
+ {
+ border-right: 8px solid black;
+ margin-right: -104px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1">
+ <div id="div2"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-001.xht
new file mode 100644
index 0000000000..064a20aa0c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-001.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right applied to element with display table-row-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property does not apply to elements with a display of table-row-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #test
+ {
+ display: table-row-group;
+ padding-right: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-right: 10px solid blue;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-002.xht
new file mode 100644
index 0000000000..cc90783b79
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-002.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right applied to element with display table-header-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property does not apply to elements with a display of table-header-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #test
+ {
+ display: table-header-group;
+ padding-right: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-right: 10px solid blue;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-003.xht
new file mode 100644
index 0000000000..c6f64bfd89
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-003.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right applied to element with display table-footer-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property does not apply to elements with a display of table-footer-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #test
+ {
+ display: table-footer-group;
+ padding-right: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-right: 10px solid blue;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-004.xht
new file mode 100644
index 0000000000..b9d8dba160
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-004.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right applied to element with display table-row</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property does not apply to elements with a display of table-row." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ padding-right: 50px;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-right: 10px solid blue;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-005.xht
new file mode 100644
index 0000000000..eb83d114f1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-005.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right applied to element with display table-column-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property does not apply to elements with a display of table-column-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #test
+ {
+ display: table-column-group;
+ padding-right: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-right: 10px solid blue;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-006.xht
new file mode 100644
index 0000000000..c40566ecd8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-006.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right applied to element with display table-column</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property does not apply to elements with a display of table-column." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #test
+ {
+ display: table-column;
+ padding-right: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-right: 10px solid blue;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-007.xht
new file mode 100644
index 0000000000..23dec69789
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-007.xht
@@ -0,0 +1,44 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right applied to element with display table-cell</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property applies to elements with a display of table-cell." />
+ <style type="text/css">
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-right: 10px solid orange;
+ display: table-cell;
+ padding-right: 50px;
+ }
+ #cell div
+ {
+ border-right: 10px solid blue;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-008.xht
new file mode 100644
index 0000000000..3e6cbd244d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-008.xht
@@ -0,0 +1,32 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right applied to element with display inline</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <meta name="assert" content="The 'padding-right' property applies to elements with a display of inline." />
+ <style type="text/css">
+ div
+ {
+ display: inline;
+ }
+ #div1
+ {
+ border-right: 5px solid blue;
+ padding-right: 50px;
+ }
+ div div
+ {
+ border-right: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="div1">
+ <div>Filler Text</div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-009.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-009.xht
new file mode 100644
index 0000000000..7da7cff80e
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-009.xht
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right applied to element with display block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property applies to elements with a display of block." />
+ <style type="text/css">
+ div
+ {
+ float: left;
+ }
+ span
+ {
+ display: block;
+ height: 200px;
+ }
+ #span1
+ {
+ border-right: 10px solid orange;
+ padding-right: 50px;
+ }
+ span span
+ {
+ border-right: 10px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div>
+ <span id="span1">
+ <span></span>
+ </span>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-010.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-010.xht
new file mode 100644
index 0000000000..40f36b1fb5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-010.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right applied to element with display list-item</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <meta name="assert" content="The 'padding-right' property applies to elements with a display of list-item." />
+ <style type="text/css">
+ div
+ {
+ height: 200px;
+ }
+ #div1
+ {
+ border-right: 10px solid blue;
+ display: list-item;
+ margin-left: 2em;
+ padding-right: 50px;
+ width: 10px;
+ }
+ div div
+ {
+ border-right: 10px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines and there is a marker bullet on the left-hand side of the lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-012.xht
new file mode 100644
index 0000000000..543d350b99
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-012.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right applied to element with display inline-block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property applies to elements with a display of inline-block." />
+ <style type="text/css">
+ div
+ {
+ height: 200px;
+ display: inline-block;
+ }
+ #div1
+ {
+ border-right: 10px solid orange;
+ padding-right: 50px;
+ }
+ div div
+ {
+ border-right: 10px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-013.xht
new file mode 100644
index 0000000000..5de3e8b15c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-013.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right applied to element with display table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property applies to elements with a display of table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #table
+ {
+ display: table;
+ padding-right: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-right: 10px solid blue;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-014.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-014.xht
new file mode 100644
index 0000000000..3a172ffb0f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-014.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right applied to element with display inline-table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property applies to elements with a display of inline-table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-right: 10px solid orange;
+ float: left;
+ }
+ #table
+ {
+ display: inline-table;
+ padding-right: 50px;
+ vertical-align: top;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-right: 10px solid blue;
+ height: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-015.xht
new file mode 100644
index 0000000000..f8c9a6d3d7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-right-applies-to-015.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-right applied to element with display table-caption</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-right" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-left-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding-right' property applies to elements with a display of table-caption." />
+ <style type="text/css">
+ #test
+ {
+ border-right: 10px solid orange;
+ display: table-caption;
+ padding-right: 50px;
+ }
+ #test div
+ {
+ border-right: 10px solid blue;
+ height: 200px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="table">
+ <div id="test">
+ <div></div>
+ </div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-001.xht
new file mode 100644
index 0000000000..b53cad102d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-001.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding shorthand - One value application to all sides</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-shorthand-001-ref.xht" />
+
+ <meta name="flags" content="image" />
+ <meta name="assert" content="Applying a single value to the padding property replicates it to all sides of the element." />
+ <style type="text/css">
+ #div1
+ {
+ background: url('support/shorthand-001.png') -5px;
+ border: 5px green solid;
+ padding: 20px;
+ width: 160px;
+ }
+ div div
+ {
+ background: green;
+ height: 160px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-002.xht
new file mode 100644
index 0000000000..078b58a4f8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-002.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding shorthand - two values application top, bottom and left, right</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-shorthand-002-ref.xht" />
+
+ <meta name="flags" content="image" />
+ <meta name="assert" content="Applying two values to the padding property applies the first value to the top and bottom and the second to the left and right." />
+ <style type="text/css">
+ #div1
+ {
+ background: url('support/shorthand-002.png') -5px;
+ border: 5px green solid;
+ padding: 10px 50px;
+ width: 100px;
+ }
+ div div
+ {
+ background: green;
+ height: 160px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a filled green rectangle and <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-003.xht
new file mode 100644
index 0000000000..83820a2f1d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-003.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding shorthand - three values application top and left, right and bottom</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-shorthand-003-ref.xht" />
+
+ <meta name="flags" content="image" />
+ <meta name="assert" content="Applying three values to the padding property applies the first value to the top the second value to the left and right and the third value to the bottom." />
+ <style type="text/css">
+ #div1
+ {
+ background: url('support/shorthand-003.png') -5px;
+ border: 5px green solid;
+ padding: 5px 20px 50px;
+ width: 160px;
+ }
+ div div
+ {
+ background: green;
+ height: 160px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a filled green rectangle and <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-004.xht
new file mode 100644
index 0000000000..36181dbf3d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-shorthand-004.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding shorthand - Four values application top, left, right, bottom</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-shorthand-003-ref.xht" />
+
+ <meta name="flags" content="image" />
+ <meta name="assert" content="Applying four values to the padding property applies the values top, right, bottom, left, respectively." />
+ <style type="text/css">
+ #div1
+ {
+ background: url('support/shorthand-004.png') -5px;
+ border: 5px green solid;
+ padding: 5px 20px 50px 100px;
+ width: 80px;
+ }
+ div div
+ {
+ background: green;
+ height: 160px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is a filled green rectangle and <strong>no red</strong>.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-001.xht
new file mode 100644
index 0000000000..4b5db15a48
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-001.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using pixels with a minimum minus one value, -1px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum minus one length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -1px;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-002.xht
new file mode 100644
index 0000000000..9c6eaa520c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-002.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using pixels with a minimum value, 0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a minimum length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: 0px;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-003.xht
new file mode 100644
index 0000000000..8bbfcdf06d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-003.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using pixels with a minimum plus one value, 1px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a minimum plus one length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 2px solid red;
+ padding-top: 1px;
+ }
+ #div2
+ {
+ border-bottom: 2px solid black;
+ margin-top: -3px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-004.xht
new file mode 100644
index 0000000000..7ae654e336
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-004.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using pixels with a negative zero value, -0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a negative zero length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -0px;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-005.xht
new file mode 100644
index 0000000000..c34e338861
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-005.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using pixels with a positive zero value, +0px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a positive zero length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: +0px;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-006.xht
new file mode 100644
index 0000000000..16dee77f39
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-006.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using pixels with a nominal value, 96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in pixels." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 2px solid red;
+ padding-top: 96px;
+ }
+ #div2
+ {
+ border-bottom: 2px solid black;
+ margin-top: -98px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-007.xht
new file mode 100644
index 0000000000..bf0387b1b8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-007.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using pixels with a nominal value with a plus sign, +96px</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-007-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in pixels with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 2px solid red;
+ padding-top: +96px;
+ }
+ #div2
+ {
+ border-bottom: 2px solid black;
+ margin-top: -98px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-012.xht
new file mode 100644
index 0000000000..87b44ee12f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-012.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using points with a minimum minus one value, -1pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum minus one length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -1pt;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-013.xht
new file mode 100644
index 0000000000..c4d223c7df
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-013.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using points with a minimum value, 0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a minimum length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: 0pt;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-014.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-014.xht
new file mode 100644
index 0000000000..ba4ba93f4f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-014.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using points with a minimum plus one value, 1pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a minimum plus one length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 72pt solid red;
+ padding-top: 1pt;
+ }
+ #div2
+ {
+ border-bottom: 72pt solid black;
+ margin-top: -73pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-015.xht
new file mode 100644
index 0000000000..88075b88fc
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-015.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using points with a negative zero value, -0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a negative zero length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -0pt;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-016.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-016.xht
new file mode 100644
index 0000000000..0560ed9d31
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-016.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using points with a positive zero value, +0pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a positive zero length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: +0pt;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-017.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-017.xht
new file mode 100644
index 0000000000..d170fbe729
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-017.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using points with a nominal value, 72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-019-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in points." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 6pt solid red;
+ padding-top: 72pt;
+ }
+ #div2
+ {
+ border-bottom: 6pt solid black;
+ margin-top: -78pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-018.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-018.xht
new file mode 100644
index 0000000000..0e019bef68
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-018.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using points with a nominal value with a plus sign, +72pt</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-019-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in points with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 6pt solid red;
+ padding-top: +72pt;
+ }
+ #div2
+ {
+ border-bottom: 6pt solid black;
+ margin-top: -78pt;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-023.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-023.xht
new file mode 100644
index 0000000000..a5317b0228
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-023.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using picas with a minimum minus one value, -1pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum minus one length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -1pc;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-024.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-024.xht
new file mode 100644
index 0000000000..fc82fc181f
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-024.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using picas with a minimum value, 0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a minimum length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: 0pc;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-025.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-025.xht
new file mode 100644
index 0000000000..8e2a4f8d76
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-025.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using picas with a minimum plus one value, 1pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a minimum plus one length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 1pc solid red;
+ padding-top: 1pc;
+ }
+ #div2
+ {
+ border-bottom: 1pc solid black;
+ margin-top: -2pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-026.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-026.xht
new file mode 100644
index 0000000000..f4f1c04a7c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-026.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using picas with a negative zero value, -0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a negative zero length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -0pc;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-027.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-027.xht
new file mode 100644
index 0000000000..f5f24da22b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-027.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using picas with a positive zero value, +0pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a positive zero length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: +0pc;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-028.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-028.xht
new file mode 100644
index 0000000000..10ab6625b9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-028.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using picas with a nominal value, 6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in picas." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 1pc solid red;
+ padding-top: 6pc;
+ }
+ #div2
+ {
+ border-bottom: 1pc solid black;
+ margin-top: -7pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-029.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-029.xht
new file mode 100644
index 0000000000..7cb22be7a3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-029.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using picas with a nominal value with a plus sign, +6pc</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in picas with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 1pc solid red;
+ padding-top: +6pc;
+ }
+ #div2
+ {
+ border-bottom: 1pc solid black;
+ margin-top: -7pc;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-034.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-034.xht
new file mode 100644
index 0000000000..a99427a3e8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-034.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using centimeters with a minimum minus one value, -1cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum minus one length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -1cm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-035.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-035.xht
new file mode 100644
index 0000000000..15c5eb7796
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-035.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using centimeters with a minimum value, 0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a minimum length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: 0cm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-036.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-036.xht
new file mode 100644
index 0000000000..71bb43c4de
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-036.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using centimeters with a minimum plus one value, 1cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum plus one length value in centimeters." />
+ <style type="text/css">
+ div
+ {
+ width: 50px;
+ }
+ .parent1
+ {
+ background: red;
+ min-height: 37px
+ }
+ .test1, .test2
+ {
+ padding-top: 1cm;
+ }
+ .test1
+ {
+ background: green;
+ }
+ .test2
+ {
+ background: red;
+ }
+ .child1
+ {
+ background: green;
+ height: 38px;
+ margin-top: -1cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div class="parent1">
+ <div class="test1"></div>
+ </div>
+ <br />
+ <div class="test2">
+ <div class="child1"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-037.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-037.xht
new file mode 100644
index 0000000000..2b8ebc610d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-037.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using centimeters with a negative zero value, -0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a negative zero length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -0cm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-038.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-038.xht
new file mode 100644
index 0000000000..e41d129749
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-038.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using centimeters with a positive zero value, +0cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a positive zero length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: +0cm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-039.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-039.xht
new file mode 100644
index 0000000000..b52d110f4c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-039.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using centimeters with a nominal value, 2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in centimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 2.54cm solid red;
+ padding-top: 2.54cm;
+ }
+ #div2
+ {
+ border-bottom: 2.54cm solid black;
+ margin-top: -5.08cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-040.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-040.xht
new file mode 100644
index 0000000000..ca99e58de2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-040.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using centimeters with a nominal value with a plus sign, +2.54cm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in centimeters with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 2.54cm solid red;
+ padding-top: +2.54cm;
+ }
+ #div2
+ {
+ border-bottom: 2.54cm solid black;
+ margin-top: -5.08cm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-045.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-045.xht
new file mode 100644
index 0000000000..6cb435e37b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-045.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using millimeters with a minimum minus one value, -1mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum minus one length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -1mm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-046.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-046.xht
new file mode 100644
index 0000000000..348db0eabe
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-046.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using millimeters with a minimum value, 0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a minimum length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: 0mm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-047.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-047.xht
new file mode 100644
index 0000000000..d66dc2fd5a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-047.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using millimeters with a minimum plus one value, 1mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum plus one length value in millimeters." />
+ <style type="text/css">
+ div
+ {
+ width: 50px;
+ }
+ .parent1
+ {
+ background: red;
+ min-height: 3px
+ }
+ .test1, .test2
+ {
+ padding-top: 1mm;
+ }
+ .test1
+ {
+ background: green;
+ }
+ .test2
+ {
+ background: red;
+ }
+ .child1
+ {
+ background: green;
+ height: 4px;
+ margin-top: -1mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div class="parent1">
+ <div class="test1"></div>
+ </div>
+ <br />
+ <div class="test2">
+ <div class="child1"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-048.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-048.xht
new file mode 100644
index 0000000000..7a19528560
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-048.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using millimeters with a negative zero value, -0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a negative zero length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -0mm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-049.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-049.xht
new file mode 100644
index 0000000000..4521515e65
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-049.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using millimeters with a positive zero value, +0mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a positive zero length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: +0mm;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-050.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-050.xht
new file mode 100644
index 0000000000..51aabd4829
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-050.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using millimeters with a nominal value, 25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in millimeters." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 25.4mm solid red;
+ padding-top: 25.4mm;
+ }
+ #div2
+ {
+ border-bottom: 25.4mm solid black;
+ margin-top: -50.8mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-051.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-051.xht
new file mode 100644
index 0000000000..27ef8d7ebd
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-051.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using millimeters with a nominal value with a plus sign, +25.4mm</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in millimeters with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 25.4mm solid red;
+ padding-top: +25.4mm;
+ }
+ #div2
+ {
+ border-bottom: 25.4mm solid black;
+ margin-top: -50.8mm;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-056.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-056.xht
new file mode 100644
index 0000000000..abbe774e49
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-056.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using inches with a minimum minus one value, -1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum minus one length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -1in;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-057.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-057.xht
new file mode 100644
index 0000000000..141b2a4f6a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-057.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using inches with a minimum value, 0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a minimum length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: 0in;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-058.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-058.xht
new file mode 100644
index 0000000000..b06aad202d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-058.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using inches with a minimum plus one value, 1in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a minimum plus one length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 1in solid red;
+ padding-top: 1in;
+ }
+ #div2
+ {
+ border-bottom: 1in solid black;
+ margin-top: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-059.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-059.xht
new file mode 100644
index 0000000000..079e7f25d6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-059.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using inches with a negative zero value, -0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a negative zero length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -0in;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-060.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-060.xht
new file mode 100644
index 0000000000..5cf203b0a3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-060.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using inches with a positive zero value, +0in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a positive zero length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: +0in;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-061.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-061.xht
new file mode 100644
index 0000000000..297c43555b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-061.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using inches with a nominal value, 2in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in inches." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 1in solid red;
+ padding-top: 2in;
+ }
+ #div2
+ {
+ border-bottom: 1in solid black;
+ margin-top: -3in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-062.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-062.xht
new file mode 100644
index 0000000000..1d24a82b32
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-062.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using inches with a nominal value with a plus sign, +2in</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-043-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in inches with a plus sign." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 1in solid red;
+ padding-top: +2in;
+ }
+ #div2
+ {
+ border-bottom: 1in solid black;
+ margin-top: -3in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-067.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-067.xht
new file mode 100644
index 0000000000..bd01846cf0
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-067.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using 'em' units with a minimum minus one value, -1em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem invalid" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum minus one length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -1em;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-068.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-068.xht
new file mode 100644
index 0000000000..7679ece32b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-068.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using 'em' units with a minimum value, 0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: 0em;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-069.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-069.xht
new file mode 100644
index 0000000000..1201441d08
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-069.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using 'em' units with a minimum plus one value, 1em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum plus one length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1em solid red;
+ padding-top: 1em;
+ }
+ #div2
+ {
+ border-bottom: 1em solid black;
+ margin-top: -2em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-070.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-070.xht
new file mode 100644
index 0000000000..4cee7eb715
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-070.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using 'em' units with a negative zero value, -0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-top' property handles a negative zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -0em;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-071.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-071.xht
new file mode 100644
index 0000000000..32a3a33232
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-071.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using 'em' units with a positive zero value, +0em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-top' property handles a positive zero length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: +0em;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-072.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-072.xht
new file mode 100644
index 0000000000..91b5197c6c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-072.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using 'em' units with a nominal value, 6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in 'em' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1em solid red;
+ padding-top: 6em;
+ }
+ #div2
+ {
+ border-bottom: 1em solid black;
+ margin-top: -7em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-073.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-073.xht
new file mode 100644
index 0000000000..7e0dfd3d72
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-073.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using 'em' units with a nominal value with a plus sign, +6em</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-079-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in 'em' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1em solid red;
+ padding-top: +6em;
+ }
+ #div2
+ {
+ border-bottom: 1em solid black;
+ margin-top: -7em;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-078.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-078.xht
new file mode 100644
index 0000000000..04e40d6f84
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-078.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using 'ex' units with a minimum minus one value, -1ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem invalid" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum minus one length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -1ex;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-079.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-079.xht
new file mode 100644
index 0000000000..e8ee3606ec
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-079.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using 'ex' units with a minimum value, 0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: 0ex;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-080.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-080.xht
new file mode 100644
index 0000000000..2ab113a5a9
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-080.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using 'ex' units with a minimum plus one value, 1ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum plus one length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1ex solid red;
+ padding-top: 1ex;
+ }
+ #div2
+ {
+ border-bottom: 1ex solid black;
+ margin-top: -2ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-081.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-081.xht
new file mode 100644
index 0000000000..71932ec4fd
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-081.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using 'ex' units with a negative zero value, -0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-top' property handles a negative zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -0ex;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-082.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-082.xht
new file mode 100644
index 0000000000..da2afd6094
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-082.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using 'ex' units with a positive zero value, +0ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-top' property handles a positive zero length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: +0ex;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-083.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-083.xht
new file mode 100644
index 0000000000..3ecf9cc931
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-083.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using 'ex' units with a nominal value, 6ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in 'ex' units." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1ex solid red;
+ padding-top: 6ex;
+ }
+ #div2
+ {
+ border-bottom: 1ex solid black;
+ margin-top: -7ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-084.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-084.xht
new file mode 100644
index 0000000000..4ba9db81f1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-084.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using 'ex' units with a nominal value with a plus sign, +6ex</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-031-ref.xht" />
+
+ <meta name="flags" content="ahem" />
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in 'ex' units with a plus sign." />
+ <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
+ <style type="text/css">
+ div
+ {
+ font: 20px/1 Ahem;
+ }
+ #div1
+ {
+ border-top: 1ex solid red;
+ padding-top: +6ex;
+ }
+ #div2
+ {
+ border-bottom: 1ex solid black;
+ margin-top: -7ex;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-089.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-089.xht
new file mode 100644
index 0000000000..cb0528837c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-089.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using percentage with a minimum minus one value, -1%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-bottom-100-ref.xht" />
+
+ <meta name="flags" content="invalid" />
+ <meta name="assert" content="The 'padding-top' property handles a minimum minus one length value in percentage." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -1%;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-090.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-090.xht
new file mode 100644
index 0000000000..3d9400fbd7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-090.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using percentage with a minimum value, 0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-bottom-100-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a minimum length value in percentage." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: 0%;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-091-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-091-ref.xht
new file mode 100644
index 0000000000..7980753a53
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-091-ref.xht
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-top: black solid 10px;
+ width: 200px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-091.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-091.xht
new file mode 100644
index 0000000000..e091557d07
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-091.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using percentage with a minimum plus one value, 1%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-top-091-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a minimum plus one length value in percentage." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 200px;
+ }
+ #div1
+ {
+ border-top: 10px solid red;
+ padding-top: 1%;
+ }
+ #div2
+ {
+ border-bottom: 10px solid black;
+ margin-top: -12px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-092.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-092.xht
new file mode 100644
index 0000000000..59a4c7e2fb
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-092.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using percentage with a negative zero value, -0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-bottom-100-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a negative zero length value in percentage." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -0%;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-093.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-093.xht
new file mode 100644
index 0000000000..89e1cc83e3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-093.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using percentage with a positive zero value, +0%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-bottom-100-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a positive zero length value in percentage." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 1in;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: +0%;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-094.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-094.xht
new file mode 100644
index 0000000000..f91b8146f5
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-094.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using percentage with a nominal value, 50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-103-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in percentage." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 2in;
+ }
+ #div1
+ {
+ border-top: 1in solid red;
+ padding-top: 50%;
+ }
+ #div2
+ {
+ border-bottom: 1in solid black;
+ margin-top: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-095.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-095.xht
new file mode 100644
index 0000000000..c9ffe4766b
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-095.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using percentage with a nominal value with a plus sign, +50%</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-103-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a nominal length value in percentage with a plus sign." />
+ <style type="text/css">
+ #wrapper
+ {
+ width: 2in;
+ }
+ #div1
+ {
+ border-top: 1in solid red;
+ padding-top: +50%;
+ }
+ #div2
+ {
+ border-bottom: 1in solid black;
+ margin-top: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-100.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-100.xht
new file mode 100644
index 0000000000..cfb63c36c1
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-100.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top with a negative zero value and no units, -0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a negative zero length value with no units." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: -0;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-101.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-101.xht
new file mode 100644
index 0000000000..932b911422
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-101.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top with a zero value and no units, 0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a zero length value with no units." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: 0;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-102.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-102.xht
new file mode 100644
index 0000000000..0d2930f517
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-102.xht
@@ -0,0 +1,29 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top with a positive zero value and no units, +0</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="../reference/ref-no-vert-space-between.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles a positive zero length value with no units." />
+ <style type="text/css">
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: +0;
+ }
+ #div2
+ {
+ border-bottom: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-103-ref.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-103-ref.xht
new file mode 100644
index 0000000000..bf144a4f80
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-103-ref.xht
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <head>
+
+ <title>CSS Reftest Reference</title>
+
+ <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+
+ <style type="text/css"><![CDATA[
+ div
+ {
+ border-top: black solid 96px;
+ margin-top: 112px;
+ }
+ ]]></style>
+
+ </head>
+
+ <body>
+
+ <p>Test passes if there is <strong>no red</strong>.</p>
+
+ <div></div>
+
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-103.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-103.xht
new file mode 100644
index 0000000000..d7162a0c40
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-103.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top using the 'inherit' value</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="padding-top-103-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property handles the 'inherit' value." />
+ <style type="text/css">
+ #wrapper
+ {
+ padding-top: 1in;
+ }
+ #div1
+ {
+ border-top: 1in solid red;
+ padding-top: inherit;
+ }
+ #div2
+ {
+ border-bottom: 1in solid black;
+ margin-top: -2in;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no red</strong>.</p>
+ <div id="wrapper">
+ <div id="div1"></div>
+ <div id="div2"></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-001.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-001.xht
new file mode 100644
index 0000000000..a97620f9bd
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-001.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top applied to element with display table-row-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property does not apply to elements with a display of table-row-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #test
+ {
+ display: table-row-group;
+ padding-top: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-top: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-002.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-002.xht
new file mode 100644
index 0000000000..bf11834db0
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-002.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top applied to element with display table-header-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property does not apply to elements with a display of table-header-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #test
+ {
+ display: table-header-group;
+ padding-top: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-top: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-003.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-003.xht
new file mode 100644
index 0000000000..5f84f072ab
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-003.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top applied to element with display table-footer-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property does not apply to elements with a display of table-footer-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #test
+ {
+ display: table-footer-group;
+ padding-top: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-top: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-004.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-004.xht
new file mode 100644
index 0000000000..404e7b18f2
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-004.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top applied to element with display table-row</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property does not apply to elements with a display of table-row." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ padding-top: 50px;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-top: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-005.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-005.xht
new file mode 100644
index 0000000000..0d014ddfb4
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-005.xht
@@ -0,0 +1,54 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top applied to element with display table-column-group</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property does not apply to elements with a display of table-column-group." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #test
+ {
+ display: table-column-group;
+ padding-top: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-top: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-006.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-006.xht
new file mode 100644
index 0000000000..82ba6a1601
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-006.xht
@@ -0,0 +1,54 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top applied to element with display table-column</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-applies-to-001-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property does not apply to elements with a display of table-column." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #test
+ {
+ display: table-column;
+ padding-top: 50px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-top: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is <strong>no space between</strong> the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="test"></div>
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-007.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-007.xht
new file mode 100644
index 0000000000..7c8da679ef
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-007.xht
@@ -0,0 +1,44 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top applied to element with display table-cell</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-applies-to-012-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property applies to elements with a display of table-cell." />
+ <style type="text/css">
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ border-top: 10px solid blue;
+ display: table-cell;
+ padding-top: 50px;
+ }
+ #cell div
+ {
+ border-top: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-008.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-008.xht
new file mode 100644
index 0000000000..7302f33f0a
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-008.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top applied to element with display inline</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <meta name="assert" content="The 'padding-top' property applies to elements with a display of inline." />
+ <style type="text/css">
+ p
+ {
+ margin-bottom: 100px;
+ }
+ div
+ {
+ display: inline;
+ }
+ #div1
+ {
+ border-top: 5px solid blue;
+ padding-top: 50px;
+ }
+ div div
+ {
+ border-top: 5px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="div1">
+ <div>Filler Text</div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-009.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-009.xht
new file mode 100644
index 0000000000..c743a8fa20
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-009.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top applied to element with display block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-bottom-applies-to-009-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property applies to elements with a display of block." />
+ <style type="text/css">
+ span
+ {
+ display: block;
+ }
+ #span1
+ {
+ border-top: 10px solid orange;
+ padding-top: 50px;
+ }
+ span span
+ {
+ border-top: 10px solid blue;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div>
+ <span id="span1">
+ <span></span>
+ </span>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-010.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-010.xht
new file mode 100644
index 0000000000..2ca791d3fc
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-010.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top applied to element with display list-item</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <meta name="assert" content="The 'padding-top' property applies to elements with a display of list-item." />
+ <style type="text/css">
+ div
+ {
+ width: 200px;
+ }
+ #div1
+ {
+ border-top: 10px solid blue;
+ display: list-item;
+ margin-left: 2em;
+ padding-top: 50px;
+ }
+ div div
+ {
+ border-top: 10px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines and there is a marker bullet on the left-hand side of the lines. (Note the marker bullet does not need to be aligned with either line.)</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-012.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-012.xht
new file mode 100644
index 0000000000..a050ba3fce
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-012.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top applied to element with display inline-block</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-applies-to-012-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property applies to elements with a display of inline-block." />
+ <style type="text/css">
+ div
+ {
+ width: 200px;
+ }
+ #div1
+ {
+ border-top: 10px solid blue;
+ display: inline-block;
+ padding-top: 50px;
+ }
+ div div
+ {
+ border-top: 10px solid orange;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="div1">
+ <div></div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-013.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-013.xht
new file mode 100644
index 0000000000..a8296ad0b6
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-013.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top applied to element with display table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-applies-to-013-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property applies to elements with a display of table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #table
+ {
+ display: table;
+ padding-top: 50px;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-top: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-014.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-014.xht
new file mode 100644
index 0000000000..4759548cfe
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-014.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top applied to element with display inline-table</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-applies-to-013-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property applies to elements with a display of inline-table." />
+ <style type="text/css">
+ #wrapper
+ {
+ border-top: 10px solid blue;
+ }
+ #table
+ {
+ display: inline-table;
+ padding-top: 50px;
+ vertical-align: top;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ #cell div
+ {
+ border-top: 10px solid orange;
+ width: 200px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="wrapper">
+ <div id="table">
+ <div id="row">
+ <div id="cell">
+ <div></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-015.xht b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-015.xht
new file mode 100644
index 0000000000..5b5c13f0f3
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/padding-top-applies-to-015.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <title>CSS Test: Padding-top applied to element with display table-caption</title>
+ <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
+ <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-08-25 -->
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#propdef-padding-top" />
+ <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties" />
+ <link rel="match" href="margin-top-applies-to-012-ref.xht" />
+
+ <meta name="assert" content="The 'padding-top' property applies to elements with a display of table-caption." />
+ <style type="text/css">
+ #test
+ {
+ border-top: 10px solid blue;
+ display: table-caption;
+ padding-top: 50px;
+ }
+ #test div
+ {
+ border-top: 10px solid orange;
+ width: 200px;
+ }
+ #table
+ {
+ display: table;
+ }
+ #row
+ {
+ display: table-row;
+ }
+ #cell
+ {
+ display: table-cell;
+ }
+ </style>
+ </head>
+ <body>
+ <p>Test passes if there is space between the blue and orange lines.</p>
+ <div id="table">
+ <div id="test">
+ <div></div>
+ </div>
+ <div id="row">
+ <div id="cell"></div>
+ </div>
+ </div>
+ </body>
+</html> \ No newline at end of file
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/100x100-lime.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/100x100-lime.png
new file mode 100644
index 0000000000..1b94770080
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/100x100-lime.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/100x100-red.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/100x100-red.png
new file mode 100644
index 0000000000..57bf3ddc52
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/100x100-red.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/blue15x15.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/blue15x15.png
new file mode 100644
index 0000000000..89de32fdb8
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/blue15x15.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/diamond.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/diamond.png
new file mode 100644
index 0000000000..51112efc7c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/diamond.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/green15x15.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/green15x15.png
new file mode 100644
index 0000000000..51741584a0
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/green15x15.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-border-padding-002.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-border-padding-002.png
new file mode 100644
index 0000000000..fa6b209fda
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-border-padding-002.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-013.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-013.png
new file mode 100644
index 0000000000..ee9ad109fd
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-013.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-020.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-020.png
new file mode 100644
index 0000000000..7af2130310
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-020.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-2em-space.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-2em-space.png
new file mode 100644
index 0000000000..2c381ef4dc
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-2em-space.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-4em-space.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-4em-space.png
new file mode 100644
index 0000000000..dc338c0bfe
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/margin-collapse-4em-space.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/pattern-grg-rgr-grg.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/pattern-grg-rgr-grg.png
new file mode 100644
index 0000000000..9b88fbd811
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/pattern-grg-rgr-grg.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/pattern-rgr-grg-rgr.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/pattern-rgr-grg-rgr.png
new file mode 100644
index 0000000000..d454e3a630
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/pattern-rgr-grg-rgr.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/ring.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/ring.png
new file mode 100644
index 0000000000..061bb94eba
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/ring.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-001.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-001.png
new file mode 100644
index 0000000000..8a80e8d289
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-001.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-002.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-002.png
new file mode 100644
index 0000000000..39de6b8ada
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-002.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-003.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-003.png
new file mode 100644
index 0000000000..3dfb19cb23
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-003.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-004.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-004.png
new file mode 100644
index 0000000000..e4cd56d23c
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/shorthand-004.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-blue.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-blue.png
new file mode 100644
index 0000000000..bf2759634d
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-blue.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-green.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-green.png
new file mode 100644
index 0000000000..0aa79b0c86
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-green.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-orange.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-orange.png
new file mode 100644
index 0000000000..d3cd498b52
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-orange.png
Binary files differ
diff --git a/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-white.png b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-white.png
new file mode 100644
index 0000000000..1a7d4323d7
--- /dev/null
+++ b/testing/web-platform/tests/css/CSS2/margin-padding-clear/support/swatch-white.png
Binary files differ