Add WPT test for 'align' attribute on '<hr>'.

This commit is contained in:
Corey Farwell 2016-04-11 19:47:44 -04:00
parent bd74844537
commit 3ebf43af3a
3 changed files with 79 additions and 0 deletions

View file

@ -0,0 +1,31 @@
<!doctype html>
<meta charset=utf-8>
<style>
.hr {
color: gray;
border-style: inset;
border-width: 1px;
margin: 0.5em auto;
width: 100px;
}
.left {
margin-left: 0;
}
.right {
margin-right: 0;
}
</style>
<div class='hr'></div>
<div class='hr left'></div>
<div class='hr'></div>
<div class='hr right'></div>
<div class='hr'></div>
<div class='hr'></div>
<div class='hr left'></div>
<div class='hr'></div>
<div class='hr right'></div>
<div class='hr'></div>

View file

@ -0,0 +1,24 @@
<!doctype html>
<meta charset="utf-8">
<link rel="match" href="align-ref.html">
<style>
hr {
width: 100px;
}
</style>
<hr align=>
<hr align=left>
<hr align=center>
<hr align=right>
<hr align=foobar>
<script>
// Test the IDL attribute
const values = ['', 'left', 'center', 'right', 'foobar'];
values.forEach(value => {
const hr = document.createElement('hr');
hr.align = value;
document.body.appendChild(hr);
});
</script>