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

Unified Diff: test/cctest/test-api.cc

Issue 2270005: Make intercepted properties retrievable only by getter to be not enumerable. (Closed)
Patch Set: Created 10 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/objects.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-api.cc
diff --git a/test/cctest/test-api.cc b/test/cctest/test-api.cc
index 6254eaa708a7dff85c1c2447821b702688939ab4..a33eb949f61fe9cb3645098e3c8a675f0fad9084 100644
--- a/test/cctest/test-api.cc
+++ b/test/cctest/test-api.cc
@@ -7228,6 +7228,18 @@ THREADED_TEST(NullIndexedInterceptor) {
}
+THREADED_TEST(NamedPropertyHandlerGetterAttributes) {
+ v8::HandleScope scope;
+ v8::Handle<v8::FunctionTemplate> templ = v8::FunctionTemplate::New();
+ templ->InstanceTemplate()->SetNamedPropertyHandler(InterceptorLoadXICGetter);
+ LocalContext env;
+ env->Global()->Set(v8_str("obj"),
+ templ->GetFunction()->NewInstance());
+ ExpectTrue("obj.x === 42");
+ ExpectTrue("!obj.propertyIsEnumerable('x')");
+}
+
+
static v8::Handle<Value> ParentGetter(Local<String> name,
const AccessorInfo& info) {
ApiTestFuzzer::Fuzz();
« no previous file with comments | « src/objects.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698