mirror of
https://github.com/angular/angular
synced 2026-05-24 09:28:37 +00:00
With #51148, the `ngComponentOutlet` directive now supports inputs. This allows a less verbose and simpler API to instantiate components dynamicaly. Fixes #49875 PR Close #49915
20 lines
770 B
TypeScript
20 lines
770 B
TypeScript
import { browser, element, by } from 'protractor';
|
|
|
|
describe('Dynamic Component Loader', () => {
|
|
|
|
// The tests trigger periodic asynchronous operations (via `setInterval()`), which will prevent
|
|
// the app from stabilizing. See https://angular.io/api/core/ApplicationRef#is-stable-examples
|
|
// for more details.
|
|
// To allow the tests to complete, we will disable automatically waiting for the Angular app to
|
|
// stabilize.
|
|
beforeAll(() => browser.waitForAngularEnabled(false));
|
|
afterAll(() => browser.waitForAngularEnabled(true));
|
|
|
|
beforeEach(() => browser.get(''));
|
|
|
|
it('should load ad banner', async () => {
|
|
const headline = element(by.cssContainingText('h3', 'Featured Hero Profile'));
|
|
|
|
expect(await headline.isPresent()).toBe(true);
|
|
});
|
|
});
|