summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/html/webappapis/system-state-and-capabilities/the-navigator-object/navigator-window-controls-overlay.tentative.html
diff options
context:
space:
mode:
Diffstat (limited to 'testing/web-platform/tests/html/webappapis/system-state-and-capabilities/the-navigator-object/navigator-window-controls-overlay.tentative.html')
-rw-r--r--testing/web-platform/tests/html/webappapis/system-state-and-capabilities/the-navigator-object/navigator-window-controls-overlay.tentative.html41
1 files changed, 41 insertions, 0 deletions
diff --git a/testing/web-platform/tests/html/webappapis/system-state-and-capabilities/the-navigator-object/navigator-window-controls-overlay.tentative.html b/testing/web-platform/tests/html/webappapis/system-state-and-capabilities/the-navigator-object/navigator-window-controls-overlay.tentative.html
new file mode 100644
index 0000000000..9cff8d3163
--- /dev/null
+++ b/testing/web-platform/tests/html/webappapis/system-state-and-capabilities/the-navigator-object/navigator-window-controls-overlay.tentative.html
@@ -0,0 +1,41 @@
+<!DOCTYPE html>
+<meta charset='utf-8'>
+<title>navigator.windowControlsOverlay</title>
+
+<script src='/resources/testharness.js'></script>
+<script src='/resources/testharnessreport.js'></script>
+
+<script>
+ test(function(){
+ assert_idl_attribute(navigator, 'windowControlsOverlay');
+ }, 'the windowControlsOverlay object should exist on the navigator object');
+
+ test(function(){
+ assert_idl_attribute(navigator.windowControlsOverlay, 'visible');
+ }, 'visible should be a member of the windowControlsOverlay object');
+
+ test(function(){
+ assert_false(navigator.windowControlsOverlay.visible);
+ }, 'visible should be false');
+
+ test(function(){
+ assert_idl_attribute(navigator.windowControlsOverlay, 'getTitlebarAreaRect');
+ }, 'getTitlebarAreaRect should be a method of the windowControlsOverlay object');
+
+ test(function(){
+ var rect = navigator.windowControlsOverlay.getTitlebarAreaRect();
+ assert_true(rect instanceof DOMRect);
+ }, 'getTitlebarAreaRect return type should be DOMRect');
+
+ test(function(){
+ var rect = navigator.windowControlsOverlay.getTitlebarAreaRect();
+ assert_equals(rect.x, 0);
+ assert_equals(rect.y, 0);
+ assert_equals(rect.width, 0);
+ assert_equals(rect.height, 0);
+ }, 'getTitlebarAreaRect should return a empty DOMRect');
+
+ test(function(){
+ assert_idl_attribute(navigator.windowControlsOverlay, 'ongeometrychange');
+ }, 'ongeometrychange should be a member of the windowControlsOverlay object');
+</script>