| Index: test/mjsunit/harmony/global.js
|
| diff --git a/test/mjsunit/harmony/global.js b/test/mjsunit/harmony/global.js
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..a5157f43955de0fbf99664c4d710c404489730cb
|
| --- /dev/null
|
| +++ b/test/mjsunit/harmony/global.js
|
| @@ -0,0 +1,24 @@
|
| +// Copyright 2016 the V8 project authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +// Flags: --harmony-global
|
| +
|
| +function Test() {
|
| + var globalObject = global;
|
| + assertEquals(globalObject, global);
|
| + assertEquals(globalObject, global.global);
|
| +
|
| + var thisObject = this;
|
| + assertEquals(globalObject, thisObject);
|
| + assertEquals(globalObject, thisObject.global);
|
| +
|
| + const desc = Object.getOwnPropertyDescriptor(globalObject, 'global');
|
| + assertPropertiesEqual({
|
| + value: globalObject,
|
| + writable: true,
|
| + enumerable: false,
|
| + configurable: true
|
| + }, desc);
|
| +}
|
| +Test();
|
|
|