'mat-item' is not a known element code example

Example 1: 'mat-checkbox' is not a known element

import { MatCheckboxModule } from '@angular/material/checkbox';

TestBed.configureTestingModule({
   imports: [
        MatCheckboxModule
   ],
   declarations: [AddAlarmsFormComponent]
})

Example 2: 'mat-label' is not a known element:

// common-widgets.module.ts
import { MatFormFieldModule } from '@angular/material/form-field';
import { MatInputModule } from '@angular/material/input';

@NgModule({
  imports: [
    MatFormFieldModule,
    MatInputModule
  ]
})
export class CommonWidgetsModule { }