summaryrefslogtreecommitdiffstats
path: root/embedding/test/test_private_window_from_content.html
diff options
context:
space:
mode:
Diffstat (limited to 'embedding/test/test_private_window_from_content.html')
-rw-r--r--embedding/test/test_private_window_from_content.html12
1 files changed, 12 insertions, 0 deletions
diff --git a/embedding/test/test_private_window_from_content.html b/embedding/test/test_private_window_from_content.html
new file mode 100644
index 000000000..4b64fb232
--- /dev/null
+++ b/embedding/test/test_private_window_from_content.html
@@ -0,0 +1,12 @@
+<!DOCTYPE html>
+<script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
+<script>
+ // Make sure that we cannot open private browsing windows from unprivileged content
+ var win = window.open("about:blank", "_blank", "private");
+ ok(!SpecialPowers.isContentWindowPrivate(win));
+ win.close();
+ // Also, make sure that passing non-private doesn't make any difference either
+ win = window.open("about:blank", "_blank", "non-private");
+ ok(!SpecialPowers.isContentWindowPrivate(win));
+ win.close();
+</script>