mirror of
https://github.com/servo/servo.git
synced 2025-08-04 13:10:20 +01:00
layout: tests: Add tests for max/min inline block size
And update existing expectations
This commit is contained in:
parent
3c105082b8
commit
3d4aa46bcf
7 changed files with 179 additions and 3 deletions
|
@ -1,3 +0,0 @@
|
|||
[max-width-110.htm]
|
||||
type: reftest
|
||||
expected: FAIL
|
|
@ -3179,6 +3179,54 @@
|
|||
"url": "/_mozilla/css/marker_block_direction_placement_a.html"
|
||||
}
|
||||
],
|
||||
"css/max_inline_block_size.html": [
|
||||
{
|
||||
"path": "css/max_inline_block_size.html",
|
||||
"references": [
|
||||
[
|
||||
"/_mozilla/css/max_inline_block_size_ref.html",
|
||||
"=="
|
||||
]
|
||||
],
|
||||
"url": "/_mozilla/css/max_inline_block_size.html"
|
||||
}
|
||||
],
|
||||
"css/max_inline_block_size_canvas.html": [
|
||||
{
|
||||
"path": "css/max_inline_block_size_canvas.html",
|
||||
"references": [
|
||||
[
|
||||
"/_mozilla/css/max_inline_block_size_ref.html",
|
||||
"=="
|
||||
]
|
||||
],
|
||||
"url": "/_mozilla/css/max_inline_block_size_canvas.html"
|
||||
}
|
||||
],
|
||||
"css/max_inline_block_size_image.html": [
|
||||
{
|
||||
"path": "css/max_inline_block_size_image.html",
|
||||
"references": [
|
||||
[
|
||||
"/_mozilla/css/max_inline_block_size_ref.html",
|
||||
"=="
|
||||
]
|
||||
],
|
||||
"url": "/_mozilla/css/max_inline_block_size_image.html"
|
||||
}
|
||||
],
|
||||
"css/max_inline_block_size_ref.html": [
|
||||
{
|
||||
"path": "css/max_inline_block_size_ref.html",
|
||||
"references": [
|
||||
[
|
||||
"/_mozilla/css/max_inline_block_size_ref.html",
|
||||
"=="
|
||||
]
|
||||
],
|
||||
"url": "/_mozilla/css/max_inline_block_size_ref.html"
|
||||
}
|
||||
],
|
||||
"css/max_width_float_simple_a.html": [
|
||||
{
|
||||
"path": "css/max_width_float_simple_a.html",
|
||||
|
@ -9709,6 +9757,54 @@
|
|||
"url": "/_mozilla/css/marker_block_direction_placement_a.html"
|
||||
}
|
||||
],
|
||||
"css/max_inline_block_size.html": [
|
||||
{
|
||||
"path": "css/max_inline_block_size.html",
|
||||
"references": [
|
||||
[
|
||||
"/_mozilla/css/max_inline_block_size_ref.html",
|
||||
"=="
|
||||
]
|
||||
],
|
||||
"url": "/_mozilla/css/max_inline_block_size.html"
|
||||
}
|
||||
],
|
||||
"css/max_inline_block_size_canvas.html": [
|
||||
{
|
||||
"path": "css/max_inline_block_size_canvas.html",
|
||||
"references": [
|
||||
[
|
||||
"/_mozilla/css/max_inline_block_size_ref.html",
|
||||
"=="
|
||||
]
|
||||
],
|
||||
"url": "/_mozilla/css/max_inline_block_size_canvas.html"
|
||||
}
|
||||
],
|
||||
"css/max_inline_block_size_image.html": [
|
||||
{
|
||||
"path": "css/max_inline_block_size_image.html",
|
||||
"references": [
|
||||
[
|
||||
"/_mozilla/css/max_inline_block_size_ref.html",
|
||||
"=="
|
||||
]
|
||||
],
|
||||
"url": "/_mozilla/css/max_inline_block_size_image.html"
|
||||
}
|
||||
],
|
||||
"css/max_inline_block_size_ref.html": [
|
||||
{
|
||||
"path": "css/max_inline_block_size_ref.html",
|
||||
"references": [
|
||||
[
|
||||
"/_mozilla/css/max_inline_block_size_ref.html",
|
||||
"=="
|
||||
]
|
||||
],
|
||||
"url": "/_mozilla/css/max_inline_block_size_ref.html"
|
||||
}
|
||||
],
|
||||
"css/max_width_float_simple_a.html": [
|
||||
{
|
||||
"path": "css/max_width_float_simple_a.html",
|
||||
|
|
BIN
tests/wpt/mozilla/tests/css/250x250_green.png
Normal file
BIN
tests/wpt/mozilla/tests/css/250x250_green.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 628 B |
21
tests/wpt/mozilla/tests/css/max_inline_block_size.html
Normal file
21
tests/wpt/mozilla/tests/css/max_inline_block_size.html
Normal file
|
@ -0,0 +1,21 @@
|
|||
<!doctype html>
|
||||
<meta charset="utf-8">
|
||||
<title>Max inline-block size inside another inline-block element</title>
|
||||
<link rel="match" href="max_inline_block_size_ref.html">
|
||||
<style>
|
||||
html, body { margin: 0; padding: 0; }
|
||||
|
||||
div { display: inline-block; }
|
||||
|
||||
#a {
|
||||
background: red;
|
||||
}
|
||||
|
||||
#b {
|
||||
background: rgb(0, 255, 0);
|
||||
width: 500px;
|
||||
max-width: 250px;
|
||||
height: 250px;
|
||||
}
|
||||
</style>
|
||||
<div id="a"><div id="b"></div></div>
|
|
@ -0,0 +1,24 @@
|
|||
<!doctype html>
|
||||
<meta charset="utf-8">
|
||||
<title>Max inline-block size inside another inline-block element</title>
|
||||
<link rel="match" href="max_inline_block_size_ref.html">
|
||||
<style>
|
||||
html, body { margin: 0; padding: 0; }
|
||||
|
||||
div, canvas { display: inline-block; }
|
||||
|
||||
#a {
|
||||
background: red;
|
||||
}
|
||||
|
||||
#c {
|
||||
max-width: 250px;
|
||||
height: 250px;
|
||||
}
|
||||
</style>
|
||||
<div id="a"><canvas width="500" height="250" id="c"></canvas></div>
|
||||
<script>
|
||||
var c = document.getElementById("c").getContext("2d");
|
||||
c.fillStyle = "rgb(0, 255, 0)";
|
||||
c.fillRect(0, 0, c.canvas.width, c.canvas.height);
|
||||
</script>
|
18
tests/wpt/mozilla/tests/css/max_inline_block_size_image.html
Normal file
18
tests/wpt/mozilla/tests/css/max_inline_block_size_image.html
Normal file
|
@ -0,0 +1,18 @@
|
|||
<!doctype html>
|
||||
<meta charset="utf-8">
|
||||
<title>Max inline-block size inside another inline-block element</title>
|
||||
<link rel="match" href="max_inline_block_size_ref.html">
|
||||
<style>
|
||||
html, body { margin: 0; padding: 0; }
|
||||
|
||||
div, img { display: inline-block; }
|
||||
|
||||
#a {
|
||||
background: red;
|
||||
}
|
||||
|
||||
#b {
|
||||
max-width: 250px;
|
||||
}
|
||||
</style>
|
||||
<div id="a"><img id="b" width="500" height="250" src="250x250_green.png"></div>
|
20
tests/wpt/mozilla/tests/css/max_inline_block_size_ref.html
Normal file
20
tests/wpt/mozilla/tests/css/max_inline_block_size_ref.html
Normal file
|
@ -0,0 +1,20 @@
|
|||
<!doctype html>
|
||||
<meta charset="utf-8">
|
||||
<title>Max inline-block size inside another inline-block element</title>
|
||||
<link rel="match" href="max_inline_block_size_ref.html">
|
||||
<style>
|
||||
html, body { margin: 0; padding: 0; }
|
||||
|
||||
div { display: inline-block; }
|
||||
|
||||
#a {
|
||||
background: red;
|
||||
}
|
||||
|
||||
#b {
|
||||
background: rgb(0, 255, 0);
|
||||
width: 250px;
|
||||
height: 250px;
|
||||
}
|
||||
</style>
|
||||
<div id="a"><div id="b"></div></div>
|
Loading…
Add table
Add a link
Reference in a new issue