https://github.com/web-platform-tests/wpt
Raw File
Tip revision: 220550a5ff779548d669998a623bf6fc14f6d290 authored by Christian Biesinger on 26 January 2016, 01:17:40 UTC
[css-sizing-3] Add tests for percentage resolution
Tip revision: 220550a
idlharness.https.window.js
// META: script=/resources/WebIDLParser.js
// META: script=/resources/idlharness.js

// https://w3c.github.io/sensors/

'use strict';

function cast(i, t) {
  return Object.assign(Object.create(t.prototype), i);
}

idl_test(
  ['generic-sensor'],
  ['dom', 'html', 'WebIDL'],
  idl_array => {
    idl_array.add_objects({
      Sensor: ['cast(new Accelerometer(), Sensor)'],
      SensorErrorEvent: [
        'new SensorErrorEvent("error", { error: new DOMException });'
      ],
    });
  }
);
back to top