Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(286)

Side by Side Diff: LayoutTests/wake_lock/wakelock-api.html

Issue 1084923002: Wake Lock API implementation (Blink part) (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <html>
3 <body>
4 <script src="../resources/testharness.js"></script>
5 <script src="../resources/testharnessreport.js"></script>
6 <script>
7
8 test(function() {
9 assert_idl_attribute(screen, 'keepAwake');
10 assert_equals(typeof screen.keepAwake, 'boolean');
11 }, 'Test that the WakeLock API is present.');
12
13 test(function() {
14 screen.keepAwake = true;
15 assert_true(screen.keepAwake);
16
17 screen.keepAwake = false;
18 assert_false(screen.keepAwake);
19 }, 'Test that screen.keepAwake preserves set value');
20
21 </script>
22 </body>
23 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698