We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d560da9 commit 172d522Copy full SHA for 172d522
1 file changed
src/app/component/top-header/top-header.component.spec.ts
@@ -21,4 +21,19 @@ describe('TopHeaderComponent', () => {
21
it('should create', () => {
22
expect(component).toBeTruthy();
23
});
24
+
25
+ it('check if header is being generated', () => {
26
+ const HTMLElement: HTMLElement = fixture.nativeElement;
27
+ const heading = HTMLElement.querySelector('h1')!;
28
+ expect(heading.textContent).toEqual('Default');
29
+ });
30
31
+ it('check if header is being changed', () => {
32
+ const changedTextElement = 'changed';
33
+ component.section = changedTextElement;
34
+ fixture.detectChanges();
35
36
37
+ expect(heading.textContent).toEqual('changed');
38
39
0 commit comments