34 lines
867 B
HTML
34 lines
867 B
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<script src="../../resources/js-test-pre.js"></script>
|
|
<style type='text/css'>
|
|
html, body {
|
|
margin: 0;
|
|
padding: 0;
|
|
}
|
|
input {
|
|
width: 100px;
|
|
height: 2em;
|
|
font-size: 12px;
|
|
border: 1px solid black;
|
|
}
|
|
#b {
|
|
position: absolute;
|
|
margin-left: 10px;
|
|
left: 110px;
|
|
}
|
|
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<input id="a"></input><input id="b"></input>
|
|
<div id="console"></div>
|
|
</body>
|
|
<script>
|
|
shouldBe("document.getElementById('a').getBoundingClientRect().top", '0');
|
|
shouldBe("document.getElementById('b').getBoundingClientRect().top", '0');
|
|
</script>
|
|
</html>
|
|
|