Lines Matching refs:should
689 * @param {Function} idlArrayFunc Function operating on an IdlArray that should throw.
787 assert_true(originalExists, `Original ${parsed_idl.type} should be defined`);
800 `Original ${parsed_idl.name} definition should have type ${parsed_idl.type}`);
967 assert_true(Array.isArray(value), "should be an Array");
978 assert_true("then" in value, "Attribute with a Promise type should have a then property");
986 assert_true(Array.isArray(value), "Value should be array");
987 assert_true(Object.isFrozen(value), "Value should be frozen");
1011 assert_equals(value, Math.floor(value), "should be an integer");
1012 assert_true(-128 <= value && value <= 127, "byte " + value + " should be in range [-128, 127]");
1017 assert_equals(value, Math.floor(value), "should be an integer");
1018 assert_true(0 <= value && value <= 255, "octet " + value + " should be in range [0, 255]");
1023 assert_equals(value, Math.floor(value), "should be an integer");
1024 assert_true(-32768 <= value && value <= 32767, "short " + value + " should be in range [-32768, 32767]");
1029 assert_equals(value, Math.floor(value), "should be an integer");
1030 assert_true(0 <= value && value <= 65535, "unsigned short " + value + " should be in range [0, 65535]");
1035 assert_equals(value, Math.floor(value), "should be an integer");
1036 assert_true(-2147483648 <= value && value <= 2147483647, "long " + value + " should be in range [-2147483648, 2147483647]");
1041 assert_equals(value, Math.floor(value), "should be an integer");
1042 assert_true(0 <= value && value <= 4294967295, "unsigned long " + value + " should be in range [0, 4294967295]");
1052 assert_true(0 <= value, "unsigned long long should be positive");
1057 assert_equals(value, Math.fround(value), "float rounded to 32-bit float should be itself");
1073 assert_equals(value, Math.fround(value), "unrestricted float rounded to 32-bit float should be itself");
1107 // semantics then it should go in the switch statement above. If an IDL
1108 // type needs full checking, then the test should include it in the IDL it
1217 * An indicator of whether we should run tests on the interface object and
1410 // No tests to do without an instance. TODO: We should still be able
1467 assert_false("get" in desc, "self's property " + format_value(this.name) + " should not have a getter");
1468 assert_false("set" in desc, "self's property " + format_value(this.name) + " should not have a setter");
1469 assert_true(desc.writable, "self's property " + format_value(this.name) + " should be writable");
1470 assert_false(desc.enumerable, "self's property " + format_value(this.name) + " should not be enumerable");
1471 assert_true(desc.configurable, "self's property " + format_value(this.name) + " should be configurable");
1557 assert_false("get" in desc, this.name + ".length should not have a getter");
1558 assert_false("set" in desc, this.name + ".length should not have a setter");
1559 assert_false(desc.writable, this.name + ".length should not be writable");
1560 assert_false(desc.enumerable, this.name + ".length should not be enumerable");
1561 assert_true(desc.configurable, this.name + ".length should be configurable");
1583 assert_false("get" in desc, this.name + ".name should not have a getter");
1584 assert_false("set" in desc, this.name + ".name should not have a setter");
1585 assert_false(desc.writable, this.name + ".name should not be writable");
1586 assert_false(desc.enumerable, this.name + ".name should not be enumerable");
1587 assert_true(desc.configurable, this.name + ".name should be configurable");
1626 assert_true(alias in self, alias + " should exist");
1627 assert_equals(self[alias], this.get_interface_object(), "self." + alias + " should be the same value as self." + this.get_qualified_name());
1630 assert_true(desc.writable, alias + " should be writable");
1631 assert_false(desc.enumerable, alias + " should not be enumerable");
1632 assert_true(desc.configurable, alias + " should be configurable");
1633 assert_false('get' in desc, alias + " should not have a getter");
1634 assert_false('set' in desc, alias + " should not have a setter");
1638 assert_false(alias in self, alias + " should not exist");
1669 assert_true(desc.writable, name + " should be writable");
1670 assert_false(desc.enumerable, name + " should not be enumerable");
1671 assert_true(desc.configurable, name + " should be configurable");
1672 assert_false("get" in desc, name + " should not have a getter");
1673 assert_false("set" in desc, name + " should not have a setter");
1704 assert_false(desc.writable, "prototype should not be writable");
1705 assert_false(desc.enumerable, "prototype should not be enumerable");
1706 assert_false(desc.configurable, "prototype should not be configurable");
1707 assert_false("get" in desc, "prototype should not have a getter");
1708 assert_false("set" in desc, "prototype should not have a setter");
1719 assert_false(desc.writable, "name should not be writable");
1720 assert_false(desc.enumerable, "name should not be enumerable");
1721 assert_true(desc.configurable, "name should be configurable");
1722 assert_false("get" in desc, "name should not have a getter");
1723 assert_false("set" in desc, "name should not have a setter");
1738 assert_false(desc.writable, "length should not be writable");
1739 assert_false(desc.enumerable, "length should not be enumerable");
1740 assert_true(desc.configurable, "length should be configurable");
1741 assert_false("get" in desc, "length should not have a getter");
1742 assert_false("set" in desc, "length should not have a setter");
1774 this.name + ' should not have a "prototype" property');
1788 assert_false("get" in desc, this.name + ".prototype should not have a getter");
1789 assert_false("set" in desc, this.name + ".prototype should not have a setter");
1790 assert_false(desc.writable, this.name + ".prototype should not be writable");
1791 assert_false(desc.enumerable, this.name + ".prototype should not be enumerable");
1792 assert_false(desc.configurable, this.name + ".prototype should not be configurable");
1842 'should inherit from ' + inherit_interface + ', but there is no such property');
1844 'should inherit from ' + inherit_interface + ', but that object has no "prototype" property');
1870 // String() should end up calling {}.toString if nothing defines a
1898 this.name + ' should not have a "prototype" property');
1913 assert_false("get" in desc, this.name + ".prototype.constructor should not have a getter");
1914 assert_false("set" in desc, this.name + ".prototype.constructor should not have a setter");
1915 assert_true(desc.writable, this.name + ".prototype.constructor should be writable");
1916 assert_false(desc.enumerable, this.name + ".prototype.constructor should not be enumerable");
1917 assert_true(desc.configurable, this.name + ".prototype.constructor should be configurable");
1933 this.name + ' should not have a "prototype" property');
1950 this.name + '.prototype should have an @@unscopables property');
1953 this.name + ".prototype[Symbol.unscopables] should not have a getter");
1954 assert_false("set" in desc, this.name + ".prototype[Symbol.unscopables] should not have a setter");
1955 assert_false(desc.writable, this.name + ".prototype[Symbol.unscopables] should not be writable");
1956 assert_false(desc.enumerable, this.name + ".prototype[Symbol.unscopables] should not be enumerable");
1957 assert_true(desc.configurable, this.name + ".prototype[Symbol.unscopables] should be configurable");
1959 this.name + '.prototype[Symbol.unscopables] should be in the descriptor');
1961 this.name + '.prototype[Symbol.unscopables] should be an object');
1963 this.name + '.prototype[Symbol.unscopables] should have a null prototype');
1966 this.name + '.prototype[Symbol.unscopables] should have the right number of symbol-named properties');
1969 // have all the ones we should will happen in the per-member tests.
1979 this.name + '.prototype should not have @@unscopables');
2011 "should throw a TypeError");
2053 "should throw a TypeError");
2074 "should return false");
2082 "should not throw");
2090 "should not throw");
2098 "should return true");
2123 assert_false("get" in desc, "property should not have a getter");
2124 assert_false("set" in desc, "property should not have a setter");
2125 assert_false(desc.writable, "property should not be writable");
2126 assert_true(desc.enumerable, "property should be enumerable");
2127 assert_false(desc.configurable, "property should not be configurable");
2138 this.name + ' should not have a "prototype" property');
2149 assert_false("get" in desc, "property should not have a getter");
2150 assert_false("set" in desc, "property should not have a setter");
2151 assert_false(desc.writable, "property should not be writable");
2152 assert_true(desc.enumerable, "property should be enumerable");
2153 assert_false(desc.configurable, "property should not be configurable");
2190 "The prototype object should not have a property " +
2210 "Gets on a global should not require an explicit this");
2271 this.name + ' should not have a "prototype" property');
2348 assert_false("get" in desc, "property should not have a getter");
2349 assert_false("set" in desc, "property should not have a setter");
2351 "property should be writable if and only if not unforgeable");
2352 assert_true(desc.enumerable, "property should be enumerable");
2354 "property should be configurable if and only if not unforgeable");
2380 // This should be hit if the operation is not static, there is
2419 assert_true(k in json, "property " + JSON.stringify(k) + " should be present in the output of " + this.name + ".prototype.toJSON()");
2421 assert_true(descriptor.writable, "property " + k + " should be writable");
2422 assert_true(descriptor.configurable, "property " + k + " should be configurable");
2423 assert_true(descriptor.enumerable, "property " + k + " should be enumerable");
2444 assert_true(iteratorDesc.writable, "@@iterator property should be writable");
2445 assert_true(iteratorDesc.configurable, "@@iterator property should be configurable");
2446 assert_false(iteratorDesc.enumerable, "@@iterator property should not be enumerable");
2447 assert_equals(typeof iteratorDesc.value, "function", "@@iterator property should be a function");
2448 assert_equals(iteratorDesc.value.length, 0, "@@iterator function object length should be 0");
2449 assert_equals(iteratorDesc.value.name, isPairIterator ? "entries" : "values", "@@iterator function object should have the right name");
2452 assert_equals(proto["entries"], proto[Symbol.iterator], "entries method should be the same as @@iterator method");
2460 assert_equals(typeof desc.value, "function", property + " property should be a function");
2461 assert_equals(desc.value.length, length, property + " function object should have the right length");
2462 assert_equals(desc.value.name, property, property + " function object should have the right name");
2465 assert_equals(proto[Symbol.iterator], Array.prototype[Symbol.iterator], "@@iterator method should be the same as Array prototype's");
2468 assert_equals(proto[property], Array.prototype[property], propertyName + " method should be the same as Array prototype's");
2496 assert_equals(typeof desc.value, "function", `${name} should be a function`);
2500 assert_equals(desc.value.length, length, `${name} function object length should be ${length}`);
2501 assert_equals(desc.value.name, name, `${name} function object should have the right name`);
2505 assert_equals(iteratorDesc.value, proto.entries, `@@iterator should equal entries`);
2511 assert_equals(typeof sizeDesc.get, "function", `size getter should be a function`);
2512 assert_equals(sizeDesc.set, undefined, `size should not have a setter`);
2515 assert_equals(sizeDesc.get.length, 0, `size getter length should have the right length`);
2541 assert_equals(typeof desc.value, "function", `${name} should be a function`);
2545 assert_equals(desc.value.length, length, `${name} function object length should be ${length}`);
2546 assert_equals(desc.value.name, name, `${name} function object should have the right name`);
2550 assert_equals(iteratorDesc.value, proto.values, `@@iterator should equal values`);
2556 assert_equals(typeof sizeDesc.get, "function", `size getter should be a function`);
2557 assert_equals(sizeDesc.set, undefined, `size should not have a setter`);
2560 assert_equals(sizeDesc.get.length, 0, `size getter length should have the right length`);
2573 assert_true(iteratorDesc.writable, "@@asyncIterator property should be writable");
2574 assert_true(iteratorDesc.configurable, "@@asyncIterator property should be configurable");
2575 assert_false(iteratorDesc.enumerable, "@@asyncIterator property should not be enumerable");
2576 assert_equals(typeof iteratorDesc.value, "function", "@@asyncIterator property should be a function");
2577 assert_equals(iteratorDesc.value.length, 0, "@@asyncIterator function object length should be 0");
2578 assert_equals(iteratorDesc.value.name, isPairIterator ? "entries" : "values", "@@asyncIterator function object should have the right name");
2581 assert_equals(proto["entries"], proto[Symbol.asyncIterator], "entries method should be the same as @@asyncIterator method");
2584 assert_equals(typeof desc.value, "function", property + " property should be a function");
2585 assert_equals(desc.value.length, 0, property + " function object length should be 0");
2586 assert_equals(desc.value.name, property, property + " function object should have the right name");
2589 assert_equals(proto["values"], proto[Symbol.asyncIterator], "values method should be the same as @@asyncIterator method");
2590 assert_false("entries" in proto, "should not have an entries method");
2591 assert_false("keys" in proto, "should not have a keys method");
2608 this.name + ' should not have a "prototype" property');
2625 assert_false("get" in desc, "property should not have a getter");
2626 assert_false("set" in desc, "property should not have a setter");
2628 "property should be writable if and only if not unforgeable");
2629 assert_true(desc.enumerable, "property should be enumerable");
2631 "property should be configurable if and only if not unforgeable");
3020 assert_false("value" in desc, 'property descriptor should not have a "value" field');
3021 assert_false("writable" in desc, 'property descriptor should not have a "writable" field');
3022 assert_true(desc.enumerable, "property should be enumerable");
3069 // TODO: Test calling setter on the interface prototype (should throw
3292 assert_false("get" in desc, "property should not have a getter");
3293 assert_false("set" in desc, "property should not have a setter");
3297 "property should be writable if and only if not unforgeable");
3298 assert_true(desc.enumerable, "property should be enumerable");
3302 "property should be configurable if and only if not unforgeable");
3378 assert_true(desc.writable, "namespace object should be writable");
3379 assert_false(desc.enumerable, "namespace object should not be enumerable");
3380 assert_true(desc.configurable, "namespace object should be configurable");
3381 assert_false("get" in desc, "namespace object should not have a getter");
3382 assert_false("set" in desc, "namespace object should not have a setter");