Index: third_party/WebKit/LayoutTests/plugins/plugin-scriptable.html |
diff --git a/third_party/WebKit/LayoutTests/plugins/plugin-scriptable.html b/third_party/WebKit/LayoutTests/plugins/plugin-scriptable.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..9567a1b7d496c82c75fec067feefb47360cfd20f |
--- /dev/null |
+++ b/third_party/WebKit/LayoutTests/plugins/plugin-scriptable.html |
@@ -0,0 +1,28 @@ |
+<html> |
+<head> |
+<script src="../resources/js-test.js"></script> |
+<script> |
+description("This tests checks that hasOwnProperty return true on plugin's getters that return undefined"); |
+jsTestIsAsync = true; |
bashi
2016/03/22 23:14:50
Why does this test need to be async?
|
+var ref; |
+ |
+function onLoad() { |
+ // The plugin implements testGetUndefined the same way as the following: |
+ function ReferenceObject () { |
+ Object.defineProperties(this, { |
+ "testGetUndefined": { get: function () { return undefined; } } |
+ }); |
+ } |
+ ref = new ReferenceObject(); |
+ |
+ shouldBeTrue('ref.hasOwnProperty("testGetUndefined")'); |
+ shouldBeTrue('document.getElementById("plugin").hasOwnProperty("testGetUndefined")'); |
+ |
+ finishJSTest(); |
+} |
+</script> |
+</head> |
+<body onload="onLoad()"> |
+<object id="plugin" type="application/x-blink-deprecated-test-plugin"></object> |
+</body> |
+</html> |