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

Unified Diff: test/mjsunit/harmony/proxies-cross-realm-ecxeption.js

Issue 1516843002: [proxy] fixing harmony/proxy.js tests and improving error messages + some drive-by fixes (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: WIP fix protoype walks with access checks Created 5 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « test/mjsunit/harmony/proxies.js ('k') | test/mjsunit/harmony/proxies-enumerate.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/harmony/proxies-cross-realm-ecxeption.js
diff --git a/test/mjsunit/harmony/proxies-cross-realm-ecxeption.js b/test/mjsunit/harmony/proxies-cross-realm-ecxeption.js
new file mode 100644
index 0000000000000000000000000000000000000000..3553638dffcfa0f75d4efac14e30f1d006da0c73
--- /dev/null
+++ b/test/mjsunit/harmony/proxies-cross-realm-ecxeption.js
@@ -0,0 +1,19 @@
+// Copyright 2015 the V8 project authors. All rights reserved.
dingxiangfei2009 2015/12/12 01:27:01 The file name has a typo
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --harmony-proxies
+
+// Do not read out the prototype from a cross-realm object.
+var realm = Realm.create();
+
+__proto__ = { get foo() { print("+++++++++++++"); } };
+Realm.eval(realm, "Reflect.getPrototypeOf(Realm.global(0))");
+
+// 2-level indirection
+__proto__ = new Proxy({},
+ new Proxy({}, {
+ get() { assertUnreachable() }
+ })
+);
+Realm.eval(realm, "Realm.global(0) instanceof Object");
« no previous file with comments | « test/mjsunit/harmony/proxies.js ('k') | test/mjsunit/harmony/proxies-enumerate.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698