blob: 20d361f623c2ed1aa01bbcaeec7cca779d1a58ea [file] [log] [blame]
Ben Murdoch4a90d5f2016-03-22 12:00:34 +00001// Copyright 2015 the V8 project authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5// Flags: --promise-extra
6
7'use strict';
8
9Object.defineProperties(Object.prototype, {
10 promise: {set: assertUnreachable},
11 reject: {set: assertUnreachable},
12 resolve: {set: assertUnreachable},
13});
14
15class P extends Promise {}
16
17P.all([Promise.resolve('ok')]);
18P.race([Promise.resolve('ok')]);
19P.defer();