Skip to content

Commit

Permalink
Merge css/cssom-1/ and css/cssom-view-1/ into cssom/ and cssom-view/
Browse files Browse the repository at this point in the history
The only interesting change is cssom/CSSStyleRule.html, which was
merged into css/cssom-1/cssstylerule.html (pre rename) in order to
avoid a naming conflict.

index-002.html needed changes to avoid a duplicate test name.

Also fix lint errors (tabs and setTimeout).

Fixes #5266.
  • Loading branch information
foolip authored and zcorpan committed Apr 10, 2017
1 parent c9a17c8 commit b344fa7
Show file tree
Hide file tree
Showing 149 changed files with 336 additions and 352 deletions.
88 changes: 0 additions & 88 deletions css/cssom-1/cssimportrule.html

This file was deleted.

2 changes: 0 additions & 2 deletions css/cssom-view-1/OWNERS

This file was deleted.

40 changes: 0 additions & 40 deletions css/cssom-view-1/cssom-view-window-screen-interface.html

This file was deleted.

32 changes: 0 additions & 32 deletions css/cssom-view-1/ttwf-scrollintoview.html

This file was deleted.

37 changes: 0 additions & 37 deletions css/cssom-view-1/window-screen-height.html

This file was deleted.

37 changes: 0 additions & 37 deletions css/cssom-view-1/window-screen-width.html

This file was deleted.

File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
<!DOCTYPE html>
<html>
<head>
<title>CSSOM View Module test:MediaQueryList</title>
<title>CSSOM View Module test:MediaQueryList</title>
<link rel="author" title="unbug" href="mailto:tidelgl@gmail.com" />
<link rel="help" href="http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<style type="text/css">
</style>
<style type="text/css">
</style>
</head>
<body>
<p>This case tests the MediaQueryList
<p>The test passes if the value is 1280/800</p>
<div id="log"></div>
<script>
<p>This case tests the MediaQueryList
<p>The test passes if the value is 1280/800</p>
<div id="log"></div>
<script>
test(function(){
assert_equals(window.matchMedia('(device-aspect-ratio: 1280/800)').matches, true, "Expected value for device-aspect-ratio is 1280/800");
},'matchMedia');
</script>
</script>
</body>
</html>
2 changes: 2 additions & 0 deletions cssom-view/OWNERS
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
@AutomatedTester
@plinss
@zcorpan
Original file line number Diff line number Diff line change
@@ -1,33 +1,33 @@
<!DOCTYPE html>
<html>
<head>
<title>CSSOM View Module test:Screen-pixelDepth,Screen-colorDepth</title>
<title>CSSOM View Module test:Screen-pixelDepth,Screen-colorDepth</title>
<link rel="author" title="unbug" href="mailto:tidelgl@gmail.com" />
<link rel="help" href="http://www.w3.org/TR/cssom-view/#the-screen-interface">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<style type="text/css">
</style>
<style type="text/css">
</style>
</head>
<body>
<p>This case tests the Screen pixelDepth and colorDepth</p>
<p>The test passes if the value is 24</p>
<div id="log"></div>
<script>
<p>This case tests the Screen pixelDepth and colorDepth</p>
<p>The test passes if the value is 24</p>
<div id="log"></div>
<script>
test(function(){
assert_equals(testColorDepth(), 24, "Expected value for colorDepth is 24");
},'testColorDepth');
test(function(){
assert_equals(testPixelDepth(), 24, "Expected value for pixelDepth is 24");
},'testPixelDepth');
function testColorDepth(){
var colorDepth = window.screen.colorDepth;
return colorDepth;
}
function testPixelDepth(){
var pixelDepth = window.screen.pixelDepth;
return pixelDepth;
}
</script>
function testColorDepth(){
var colorDepth = window.screen.colorDepth;
return colorDepth;
}
function testPixelDepth(){
var pixelDepth = window.screen.pixelDepth;
return pixelDepth;
}
</script>
</body>
</html>
File renamed without changes.
40 changes: 40 additions & 0 deletions cssom-view/cssom-view-window-screen-interface.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
<!DOCTYPE html>
<html>
<head>
<title>CSS Test: cssom view window screen attribute</title>
<link rel="author" title="jingke" href="mailto:jingkewhu@gmail.com">
<link rel="help" href="http://www.w3.org/TR/cssom-view/#the-screen-interface">
<meta name="flags" content="dom">
<meta name="assert" content="window screen interface">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
</head>
<body>
<div id="myDiv"></div>
<div id="log"></div>
<script>
/*test readonly*/
test(function(){assert_readonly(window.screen, "availWidth");}, "Screen.availWidth is readonly");
test(function(){assert_readonly(window.screen, "availHeight");}, "Screen.availHeight is readonly");
test(function(){assert_readonly(window.screen, "width");}, "Screen.width is readonly");
test(function(){assert_readonly(window.screen, "height");}, "Screen.height is readonly");
test(function(){assert_readonly(window.screen, "colorDepth");}, "Screen.colorDepth is readonly");
test(function(){assert_readonly(window.screen, "pixelDepth");}, "Screen.pixelDepth is readonly");


test(function(){assert_true(window.screen.width >= 0 && window.screen.width < 6000000);},
"window.screen.width >= 0 && window.screen.width < 6000000");
test(function(){assert_true(window.screen.height >= 0 && window.screen.height < 6000000);},
"window.screen.height >= 0 && window.screen.height < 6000000");
test(function(){assert_true(window.screen.availWidth >= 0 && window.screen.availWidth <= window.screen.width);},
"window.screen.availWidth >= 0 && window.screen.availWidth <= window.screen.width");
test(function(){assert_true(window.screen.availHeight >= 0 && window.screen.availHeight <= window.screen.height);},
"window.screen.availHeight >= 0 && window.screen.availHeight <= window.screen.height");
test(function(){assert_true(window.screen.colorDepth == 0 || window.screen.colorDepth == 16 || window.screen.colorDepth == 24 || window.screen.colorDepth == 32);},
"window.screen.colorDepth == 0 || window.screen.colorDepth == 16 || window.screen.colorDepth == 24 || window.screen.colorDepth == 32");
test(function(){assert_equals(window.screen.pixelDepth, window.screen.colorDepth);},
"window.screen.pixelDepth must return the value returned by window.screen.colorDepth");
</script>

</body>
</html>
File renamed without changes.
Loading

0 comments on commit b344fa7

Please sign in to comment.