blob: 9796bcd16706897d4b519b49c0ed338f87f62996 [file] [log] [blame]
<!DOCTYPE html>
<script src="../resources/testharness.js"></script>
<script src="../resources/testharnessreport.js"></script>
<script>
test(function() {
assert_throws(new TypeError, function() { new NFC(); },
'the constructor should not be callable with "new"');
assert_throws(new TypeError, function() { NFC(); },
'the constructor should not be callable');
// Test that navigator.nfc.push exists
assert_true('push' in navigator.nfc);
// Test that navigator.nfc.cancelPush exists
assert_true('cancelPush' in navigator.nfc);
// Test that navigator.nfc.watch exists
assert_true('watch' in navigator.nfc);
// Test that navigator.nfc.cancelWatch exists
assert_true('cancelWatch' in navigator.nfc);
}, 'NFC IDL test');
</script>