Skip to content

compileComponents() is asynchronous, we must use async() #4774

@wKoza

Description

@wKoza

compileComponents () is asynchronous. So, we must use async () method like this:

BeforeEach (async (() => {
     TestBed.configureTestingModule ({
       Declarations: [BannerComponent], // declare the test component
     })
     .compileComponents (); // compile template and css
   }));

not

BeforeEach (() => {
     TestBed.configureTestingModule ({
       Declarations: [BannerComponent], // declare the test component
     })
    TestBed.compileComponents (); // compile template and css
   });

So, this file must be fixed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions