Ejemplo n.º 1
0
        public void AllowScripts_SetsAllowScriptsToTrue()
        {
            var builder = new CspSandboxBuilder();

            builder.AllowScripts();
            CspSandboxOptions options = builder.BuildOptions();

            Assert.True(options.AllowScripts);
        }
Ejemplo n.º 2
0
        public void AllowSameOrigin_SetsAllowSameOriginToTrue()
        {
            var builder = new CspSandboxBuilder();

            builder.AllowSameOrigin();
            CspSandboxOptions options = builder.BuildOptions();

            Assert.True(options.AllowSameOrigin);
        }
Ejemplo n.º 3
0
        public void AllowPopupsToEscapeSandbox_SetsAllowPopupsToEscapeSandboxToTrue()
        {
            var builder = new CspSandboxBuilder();

            builder.AllowPopupsToEscapeSandbox();
            CspSandboxOptions options = builder.BuildOptions();

            Assert.True(options.AllowPopupsToEscapeSandbox);
        }
Ejemplo n.º 4
0
        public void AllowPresentation_SetsAllowPresentationToTrue()
        {
            var builder = new CspSandboxBuilder();

            builder.AllowPresentation();
            CspSandboxOptions options = builder.BuildOptions();

            Assert.True(options.AllowPresentation);
        }
Ejemplo n.º 5
0
        public void AllowPointerLock_SetsAllowPointerLockToTrue()
        {
            var builder = new CspSandboxBuilder();

            builder.AllowPointerLock();
            CspSandboxOptions options = builder.BuildOptions();

            Assert.True(options.AllowPointerLock);
        }