From c44d7ad09098c7daffe5c288c0bf75212a8d8d43 Mon Sep 17 00:00:00 2001 From: Andrew Kushnir Date: Mon, 7 Nov 2022 14:24:38 -0800 Subject: [PATCH] fixup! fix(core): hardening attribute and property binding rules for + + `, + }) + class IframeComp { + @ViewChild('container', {read: ViewContainerRef}) container!: ViewContainerRef; + @ViewChild('template') template!: TemplateRef; + + createEmbeddedView() { + this.container.createEmbeddedView(this.template); + } + } + + const fixture = TestBed.createComponent(IframeComp); + fixture.detectChanges(); + + expect(() => { + fixture.componentInstance.createEmbeddedView(); + fixture.detectChanges(); + }).toThrowError(getErrorMessageRegexp()); + + ensureNoIframePresent(fixture); + }); + describe('i18n', () => { it('should error when a security-sensitive attribute is set as ' + 'a property binding on an