summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/media-capabilities/idlharness.any.js
blob: 6da5c7d2848c2dc8a669dfcf621233c40a227c03 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
// META: script=/resources/WebIDLParser.js
// META: script=/resources/idlharness.js

// https://wicg.github.io/media-capabilities/

'use strict';

promise_test(async () => {
  idl_test(
    ['media-capabilities'],
    ['html', 'cssom-view'],
    idl_array => {
      if (self.GLOBAL.isWorker()) {
        idl_array.add_objects({ WorkerNavigator: ['navigator'] });
      } else {
        idl_array.add_objects({ Navigator: ['navigator'] });
      }
      idl_array.add_objects({
        MediaCapabilities: ['navigator.mediaCapabilities'],
        Screen: ['screen'],
        ScreenLuminance: ['screen.luminance'],
      });
    }
  );
});