35 lines
1.2 KiB
Plaintext
35 lines
1.2 KiB
Plaintext
|
Verify the various properties of String.prototype[Symbol.iterator]
|
||
|
|
||
|
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
|
||
|
|
||
|
|
||
|
Iterator object properties
|
||
|
PASS typeof String.prototype[Symbol.iterator] is "function"
|
||
|
PASS String.prototype[Symbol.iterator].name is "[Symbol.iterator]"
|
||
|
PASS String.prototype[Symbol.iterator].length is 0
|
||
|
PASS Object.getOwnPropertyDescriptor(String.prototype, Symbol.iterator).configurable is true
|
||
|
PASS Object.getOwnPropertyDescriptor(String.prototype, Symbol.iterator).enumerable is false
|
||
|
PASS Object.getOwnPropertyDescriptor(String.prototype, Symbol.iterator).writable is true
|
||
|
PASS String.prototype[Symbol.iterator]() === String.prototype[Symbol.iterator]() is false
|
||
|
Iterating a simple string.
|
||
|
PASS next.value is "W"
|
||
|
PASS next.done is false
|
||
|
PASS next.value is "e"
|
||
|
PASS next.done is false
|
||
|
PASS next.value is "b"
|
||
|
PASS next.done is false
|
||
|
PASS next.value is "K"
|
||
|
PASS next.done is false
|
||
|
PASS next.value is "i"
|
||
|
PASS next.done is false
|
||
|
PASS next.value is "t"
|
||
|
PASS next.done is false
|
||
|
PASS next.value is undefined
|
||
|
PASS next.done is true
|
||
|
PASS next.value is undefined
|
||
|
PASS next.done is true
|
||
|
PASS successfullyParsed is true
|
||
|
|
||
|
TEST COMPLETE
|
||
|
|