diff options
author | André Bargull <andre.bargull@gmail.com> | 2017-12-21 12:08:27 -0800 |
---|---|---|
committer | Rick Waldron <waldron.rick@gmail.com> | 2017-12-21 16:46:56 -0500 |
commit | ecf814bb4cfc0aa556bac79f1fbd801644b8a64e (patch) | |
tree | 0eb428cbb2b79c50f6e20b136f2291aabc5fcd9d /test | |
parent | 4337b396bd07a7e8e566045bfe230db8f51ad737 (diff) | |
download | qtdeclarative-testsuites-ecf814bb4cfc0aa556bac79f1fbd801644b8a64e.tar.gz |
No longer use testBuiltInObject for built-in constructors
Diffstat (limited to 'test')
28 files changed, 81 insertions, 37 deletions
diff --git a/test/intl402/Collator/10.1_L15.js b/test/intl402/Collator/10.1_L15.js index 0b7b5a535..84f99031d 100644 --- a/test/intl402/Collator/10.1_L15.js +++ b/test/intl402/Collator/10.1_L15.js @@ -8,7 +8,12 @@ description: > objects defined by the introduction of chapter 17 of the ECMAScript Language Specification. author: Norbert Lindenberg -includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.Collator, true, true); +assert.sameValue(Object.prototype.toString.call(Intl.Collator), "[object Function]", + "The [[Class]] internal property of a built-in function must be " + + "\"Function\"."); + +assert(Object.isExtensible(Intl.Collator), "Built-in objects must be extensible."); + +assert.sameValue(Object.getPrototypeOf(Intl.Collator), Function.prototype); diff --git a/test/intl402/Collator/prototype/10.3_L15.js b/test/intl402/Collator/prototype/10.3_L15.js index 692f2666c..bbc0450f4 100644 --- a/test/intl402/Collator/prototype/10.3_L15.js +++ b/test/intl402/Collator/prototype/10.3_L15.js @@ -8,7 +8,13 @@ description: > built-in objects defined by the introduction of chapter 17 of the ECMAScript Language Specification. author: Norbert Lindenberg -includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.Collator.prototype, false, false); +assert.sameValue(Object.prototype.toString.call(Intl.Collator.prototype), "[object Object]", + "The [[Class]] internal property of a built-in non-function object must be " + + "\"Object\"."); + +assert(Object.isExtensible(Intl.Collator.prototype), "Built-in objects must be extensible."); + +assert.sameValue(Object.getPrototypeOf(Intl.Collator.prototype), Object.prototype, + "Built-in prototype objects must have Object.prototype as their prototype."); diff --git a/test/intl402/Collator/prototype/compare/10.3.2_1_a_L15.js b/test/intl402/Collator/prototype/compare/10.3.2_1_a_L15.js index d86b720ea..09ffcf2cc 100644 --- a/test/intl402/Collator/prototype/compare/10.3.2_1_a_L15.js +++ b/test/intl402/Collator/prototype/compare/10.3.2_1_a_L15.js @@ -12,4 +12,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(new Intl.Collator().compare, true, false); +testBuiltInObject(new Intl.Collator().compare, true); diff --git a/test/intl402/Collator/prototype/compare/10.3.2_L15.js b/test/intl402/Collator/prototype/compare/10.3.2_L15.js index 4273e2628..9e35654e7 100644 --- a/test/intl402/Collator/prototype/compare/10.3.2_L15.js +++ b/test/intl402/Collator/prototype/compare/10.3.2_L15.js @@ -11,4 +11,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Object.getOwnPropertyDescriptor(Intl.Collator.prototype, "compare").get , true, false); +testBuiltInObject(Object.getOwnPropertyDescriptor(Intl.Collator.prototype, "compare").get , true); diff --git a/test/intl402/Collator/prototype/resolvedOptions/10.3.3_L15.js b/test/intl402/Collator/prototype/resolvedOptions/10.3.3_L15.js index 5ef66b88e..f41bcffc3 100644 --- a/test/intl402/Collator/prototype/resolvedOptions/10.3.3_L15.js +++ b/test/intl402/Collator/prototype/resolvedOptions/10.3.3_L15.js @@ -11,4 +11,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.Collator.prototype.resolvedOptions, true, false); +testBuiltInObject(Intl.Collator.prototype.resolvedOptions, true); diff --git a/test/intl402/Collator/supportedLocalesOf/10.2.2_L15.js b/test/intl402/Collator/supportedLocalesOf/10.2.2_L15.js index 5f9eb68d8..00618f28f 100644 --- a/test/intl402/Collator/supportedLocalesOf/10.2.2_L15.js +++ b/test/intl402/Collator/supportedLocalesOf/10.2.2_L15.js @@ -11,4 +11,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.Collator.supportedLocalesOf, true, false); +testBuiltInObject(Intl.Collator.supportedLocalesOf, true); diff --git a/test/intl402/Date/prototype/toLocaleDateString/13.3.2_L15.js b/test/intl402/Date/prototype/toLocaleDateString/13.3.2_L15.js index bf9df2db2..bd882610d 100644 --- a/test/intl402/Date/prototype/toLocaleDateString/13.3.2_L15.js +++ b/test/intl402/Date/prototype/toLocaleDateString/13.3.2_L15.js @@ -11,4 +11,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Date.prototype.toLocaleDateString, true, false); +testBuiltInObject(Date.prototype.toLocaleDateString, true); diff --git a/test/intl402/Date/prototype/toLocaleString/13.3.1_L15.js b/test/intl402/Date/prototype/toLocaleString/13.3.1_L15.js index 3e158c85a..924b02e59 100644 --- a/test/intl402/Date/prototype/toLocaleString/13.3.1_L15.js +++ b/test/intl402/Date/prototype/toLocaleString/13.3.1_L15.js @@ -11,4 +11,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Date.prototype.toLocaleString, true, false); +testBuiltInObject(Date.prototype.toLocaleString, true); diff --git a/test/intl402/Date/prototype/toLocaleTimeString/13.3.3_L15.js b/test/intl402/Date/prototype/toLocaleTimeString/13.3.3_L15.js index 37ad03f99..386d23a46 100644 --- a/test/intl402/Date/prototype/toLocaleTimeString/13.3.3_L15.js +++ b/test/intl402/Date/prototype/toLocaleTimeString/13.3.3_L15.js @@ -11,4 +11,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Date.prototype.toLocaleTimeString, true, false); +testBuiltInObject(Date.prototype.toLocaleTimeString, true); diff --git a/test/intl402/DateTimeFormat/12.1_L15.js b/test/intl402/DateTimeFormat/12.1_L15.js index 8f54cb06d..ef746f6a1 100644 --- a/test/intl402/DateTimeFormat/12.1_L15.js +++ b/test/intl402/DateTimeFormat/12.1_L15.js @@ -8,7 +8,12 @@ description: > built-in objects defined by the introduction of chapter 17 of the ECMAScript Language Specification. author: Norbert Lindenberg -includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.DateTimeFormat, true, true); +assert.sameValue(Object.prototype.toString.call(Intl.DateTimeFormat), "[object Function]", + "The [[Class]] internal property of a built-in function must be " + + "\"Function\"."); + +assert(Object.isExtensible(Intl.DateTimeFormat), "Built-in objects must be extensible."); + +assert.sameValue(Object.getPrototypeOf(Intl.DateTimeFormat), Function.prototype); diff --git a/test/intl402/DateTimeFormat/prototype/12.3_L15.js b/test/intl402/DateTimeFormat/prototype/12.3_L15.js index bf52f6a1f..d38b8d7a0 100644 --- a/test/intl402/DateTimeFormat/prototype/12.3_L15.js +++ b/test/intl402/DateTimeFormat/prototype/12.3_L15.js @@ -8,7 +8,13 @@ description: > for built-in objects defined by the introduction of chapter 17 of the ECMAScript Language Specification. author: Norbert Lindenberg -includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.DateTimeFormat.prototype, false, false); +assert.sameValue(Object.prototype.toString.call(Intl.DateTimeFormat.prototype), "[object Object]", + "The [[Class]] internal property of a built-in non-function object must be " + + "\"Object\"."); + +assert(Object.isExtensible(Intl.DateTimeFormat.prototype), "Built-in objects must be extensible."); + +assert.sameValue(Object.getPrototypeOf(Intl.DateTimeFormat.prototype), Object.prototype, + "Built-in prototype objects must have Object.prototype as their prototype."); diff --git a/test/intl402/DateTimeFormat/prototype/format/12.3.2_1_a_L15.js b/test/intl402/DateTimeFormat/prototype/format/12.3.2_1_a_L15.js index 5e27231cc..ae697b996 100644 --- a/test/intl402/DateTimeFormat/prototype/format/12.3.2_1_a_L15.js +++ b/test/intl402/DateTimeFormat/prototype/format/12.3.2_1_a_L15.js @@ -12,4 +12,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(new Intl.DateTimeFormat().format, true, false); +testBuiltInObject(new Intl.DateTimeFormat().format, true); diff --git a/test/intl402/DateTimeFormat/prototype/format/12.3.2_L15.js b/test/intl402/DateTimeFormat/prototype/format/12.3.2_L15.js index 0dc3ea121..b32367631 100644 --- a/test/intl402/DateTimeFormat/prototype/format/12.3.2_L15.js +++ b/test/intl402/DateTimeFormat/prototype/format/12.3.2_L15.js @@ -12,4 +12,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Object.getOwnPropertyDescriptor(Intl.DateTimeFormat.prototype, "format").get , true, false); +testBuiltInObject(Object.getOwnPropertyDescriptor(Intl.DateTimeFormat.prototype, "format").get , true); diff --git a/test/intl402/DateTimeFormat/prototype/resolvedOptions/12.3.3_L15.js b/test/intl402/DateTimeFormat/prototype/resolvedOptions/12.3.3_L15.js index d38b5b09a..cb294dd70 100644 --- a/test/intl402/DateTimeFormat/prototype/resolvedOptions/12.3.3_L15.js +++ b/test/intl402/DateTimeFormat/prototype/resolvedOptions/12.3.3_L15.js @@ -11,4 +11,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.DateTimeFormat.prototype.resolvedOptions, true, false); +testBuiltInObject(Intl.DateTimeFormat.prototype.resolvedOptions, true); diff --git a/test/intl402/DateTimeFormat/supportedLocalesOf/12.2.2_L15.js b/test/intl402/DateTimeFormat/supportedLocalesOf/12.2.2_L15.js index 62ab1a23f..70f8d8a5e 100644 --- a/test/intl402/DateTimeFormat/supportedLocalesOf/12.2.2_L15.js +++ b/test/intl402/DateTimeFormat/supportedLocalesOf/12.2.2_L15.js @@ -11,4 +11,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.DateTimeFormat.supportedLocalesOf, true, false); +testBuiltInObject(Intl.DateTimeFormat.supportedLocalesOf, true); diff --git a/test/intl402/Intl/8.0_L15.js b/test/intl402/Intl/8.0_L15.js index 622baa1c9..984063afc 100644 --- a/test/intl402/Intl/8.0_L15.js +++ b/test/intl402/Intl/8.0_L15.js @@ -11,5 +11,5 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(this.Intl, false, false); -testBuiltInObject(Intl, false, false); +testBuiltInObject(this.Intl, false); +testBuiltInObject(Intl, false); diff --git a/test/intl402/Number/prototype/toLocaleString/13.2.1_L15.js b/test/intl402/Number/prototype/toLocaleString/13.2.1_L15.js index aec849f83..2e426d1a9 100644 --- a/test/intl402/Number/prototype/toLocaleString/13.2.1_L15.js +++ b/test/intl402/Number/prototype/toLocaleString/13.2.1_L15.js @@ -11,4 +11,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Number.prototype.toLocaleString, true, false); +testBuiltInObject(Number.prototype.toLocaleString, true); diff --git a/test/intl402/NumberFormat/11.1_L15.js b/test/intl402/NumberFormat/11.1_L15.js index c43589cc6..7ea48e896 100644 --- a/test/intl402/NumberFormat/11.1_L15.js +++ b/test/intl402/NumberFormat/11.1_L15.js @@ -8,7 +8,12 @@ description: > objects defined by the introduction of chapter 17 of the ECMAScript Language Specification. author: Norbert Lindenberg -includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.NumberFormat, true, true); +assert.sameValue(Object.prototype.toString.call(Intl.NumberFormat), "[object Function]", + "The [[Class]] internal property of a built-in function must be " + + "\"Function\"."); + +assert(Object.isExtensible(Intl.NumberFormat), "Built-in objects must be extensible."); + +assert.sameValue(Object.getPrototypeOf(Intl.NumberFormat), Function.prototype); diff --git a/test/intl402/NumberFormat/prototype/11.3_L15.js b/test/intl402/NumberFormat/prototype/11.3_L15.js index a126a07c2..b53364781 100644 --- a/test/intl402/NumberFormat/prototype/11.3_L15.js +++ b/test/intl402/NumberFormat/prototype/11.3_L15.js @@ -8,7 +8,13 @@ description: > built-in objects defined by the introduction of chapter 17 of the ECMAScript Language Specification. author: Norbert Lindenberg -includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.NumberFormat.prototype, false, false); +assert.sameValue(Object.prototype.toString.call(Intl.NumberFormat.prototype), "[object Object]", + "The [[Class]] internal property of a built-in non-function object must be " + + "\"Object\"."); + +assert(Object.isExtensible(Intl.NumberFormat.prototype), "Built-in objects must be extensible."); + +assert.sameValue(Object.getPrototypeOf(Intl.NumberFormat.prototype), Object.prototype, + "Built-in prototype objects must have Object.prototype as their prototype."); diff --git a/test/intl402/NumberFormat/prototype/format/11.3.2_1_a_L15.js b/test/intl402/NumberFormat/prototype/format/11.3.2_1_a_L15.js index fc278baaa..4bc4a131d 100644 --- a/test/intl402/NumberFormat/prototype/format/11.3.2_1_a_L15.js +++ b/test/intl402/NumberFormat/prototype/format/11.3.2_1_a_L15.js @@ -12,4 +12,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(new Intl.NumberFormat().format, true, false); +testBuiltInObject(new Intl.NumberFormat().format, true); diff --git a/test/intl402/NumberFormat/prototype/format/11.3.2_L15.js b/test/intl402/NumberFormat/prototype/format/11.3.2_L15.js index 2c7408aed..55221edc3 100644 --- a/test/intl402/NumberFormat/prototype/format/11.3.2_L15.js +++ b/test/intl402/NumberFormat/prototype/format/11.3.2_L15.js @@ -12,4 +12,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Object.getOwnPropertyDescriptor(Intl.NumberFormat.prototype, "format").get , true, false); +testBuiltInObject(Object.getOwnPropertyDescriptor(Intl.NumberFormat.prototype, "format").get , true); diff --git a/test/intl402/NumberFormat/prototype/resolvedOptions/11.3.3_L15.js b/test/intl402/NumberFormat/prototype/resolvedOptions/11.3.3_L15.js index 113277b88..9b85acfad 100644 --- a/test/intl402/NumberFormat/prototype/resolvedOptions/11.3.3_L15.js +++ b/test/intl402/NumberFormat/prototype/resolvedOptions/11.3.3_L15.js @@ -11,4 +11,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.NumberFormat.prototype.resolvedOptions, true, false); +testBuiltInObject(Intl.NumberFormat.prototype.resolvedOptions, true); diff --git a/test/intl402/NumberFormat/supportedLocalesOf/11.2.2_L15.js b/test/intl402/NumberFormat/supportedLocalesOf/11.2.2_L15.js index c73331ea2..cbb2420c5 100644 --- a/test/intl402/NumberFormat/supportedLocalesOf/11.2.2_L15.js +++ b/test/intl402/NumberFormat/supportedLocalesOf/11.2.2_L15.js @@ -11,4 +11,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.NumberFormat.supportedLocalesOf, true, false); +testBuiltInObject(Intl.NumberFormat.supportedLocalesOf, true); diff --git a/test/intl402/PluralRules/builtin.js b/test/intl402/PluralRules/builtin.js index 4c6b53db9..99f03c8b5 100644 --- a/test/intl402/PluralRules/builtin.js +++ b/test/intl402/PluralRules/builtin.js @@ -8,7 +8,12 @@ description: > built-in objects defined by the introduction of chapter 17 of the ECMAScript Language Specification. author: Zibi Braniecki -includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.PluralRules, true, true); +assert.sameValue(Object.prototype.toString.call(Intl.PluralRules), "[object Function]", + "The [[Class]] internal property of a built-in function must be " + + "\"Function\"."); + +assert(Object.isExtensible(Intl.PluralRules), "Built-in objects must be extensible."); + +assert.sameValue(Object.getPrototypeOf(Intl.PluralRules), Function.prototype); diff --git a/test/intl402/PluralRules/prototype/builtins.js b/test/intl402/PluralRules/prototype/builtins.js index 27812e876..83ae26031 100644 --- a/test/intl402/PluralRules/prototype/builtins.js +++ b/test/intl402/PluralRules/prototype/builtins.js @@ -8,7 +8,13 @@ description: > built-in objects defined by the introduction of chapter 17 of the ECMAScript Language Specification. author: Zibi Braniecki -includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.PluralRules.prototype, false, false); +assert.sameValue(Object.prototype.toString.call(Intl.PluralRules.prototype), "[object Object]", + "The [[Class]] internal property of a built-in non-function object must be " + + "\"Object\"."); + +assert(Object.isExtensible(Intl.PluralRules.prototype), "Built-in objects must be extensible."); + +assert.sameValue(Object.getPrototypeOf(Intl.PluralRules.prototype), Object.prototype, + "Built-in prototype objects must have Object.prototype as their prototype."); diff --git a/test/intl402/PluralRules/prototype/resolvedOptions/builtins.js b/test/intl402/PluralRules/prototype/resolvedOptions/builtins.js index 442c8033f..240596c36 100644 --- a/test/intl402/PluralRules/prototype/resolvedOptions/builtins.js +++ b/test/intl402/PluralRules/prototype/resolvedOptions/builtins.js @@ -11,4 +11,4 @@ author: Zibi Braniecki includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.PluralRules.prototype.resolvedOptions, true, false); +testBuiltInObject(Intl.PluralRules.prototype.resolvedOptions, true); diff --git a/test/intl402/PluralRules/supportedLocalesOf/supportedLocalesOf.js b/test/intl402/PluralRules/supportedLocalesOf/supportedLocalesOf.js index 7115f6d13..1016f7ac6 100644 --- a/test/intl402/PluralRules/supportedLocalesOf/supportedLocalesOf.js +++ b/test/intl402/PluralRules/supportedLocalesOf/supportedLocalesOf.js @@ -11,4 +11,4 @@ author: Zibi Braniecki includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(Intl.PluralRules.supportedLocalesOf, true, false); +testBuiltInObject(Intl.PluralRules.supportedLocalesOf, true); diff --git a/test/intl402/String/prototype/localeCompare/13.1.1_L15.js b/test/intl402/String/prototype/localeCompare/13.1.1_L15.js index 624d4a3b9..c2d50ca25 100644 --- a/test/intl402/String/prototype/localeCompare/13.1.1_L15.js +++ b/test/intl402/String/prototype/localeCompare/13.1.1_L15.js @@ -11,4 +11,4 @@ author: Norbert Lindenberg includes: [testBuiltInObject.js] ---*/ -testBuiltInObject(String.prototype.localeCompare, true, false); +testBuiltInObject(String.prototype.localeCompare, true); |