Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(553)

Side by Side Diff: test/mjsunit/harmony/string-iterator.js

Issue 658423002: Unship ES6 iteration and unscopables on 3.28 (Closed) Base URL: https://v8.googlecode.com/svn/branches/3.28
Patch Set: Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Flags: --harmony-iteration
6
5 7
6 function TestStringPrototypeIterator() { 8 function TestStringPrototypeIterator() {
7 assertTrue(String.prototype.hasOwnProperty(Symbol.iterator)); 9 assertTrue(String.prototype.hasOwnProperty(Symbol.iterator));
8 assertFalse("".hasOwnProperty(Symbol.iterator)); 10 assertFalse("".hasOwnProperty(Symbol.iterator));
9 assertFalse("".propertyIsEnumerable(Symbol.iterator)); 11 assertFalse("".propertyIsEnumerable(Symbol.iterator));
10 } 12 }
11 TestStringPrototypeIterator(); 13 TestStringPrototypeIterator();
12 14
13 15
14 function assertIteratorResult(value, done, result) { 16 function assertIteratorResult(value, done, result) {
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 TestForOf(); 82 TestForOf();
81 83
82 84
83 function TestNonOwnSlots() { 85 function TestNonOwnSlots() {
84 var iterator = ""[Symbol.iterator](); 86 var iterator = ""[Symbol.iterator]();
85 var object = {__proto__: iterator}; 87 var object = {__proto__: iterator};
86 88
87 assertThrows(function() { object.next(); }, TypeError); 89 assertThrows(function() { object.next(); }, TypeError);
88 } 90 }
89 TestNonOwnSlots(); 91 TestNonOwnSlots();
OLDNEW
« no previous file with comments | « test/mjsunit/harmony/regress/regress-crbug-248025.js ('k') | test/mjsunit/harmony/typed-array-iterator.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698