-
Notifications
You must be signed in to change notification settings - Fork 6.8k
Closed
Labels
P3An issue that is relevant to core functions, but does not impede progress. Important, but not urgentAn issue that is relevant to core functions, but does not impede progress. Important, but not urgentarea: material/input
Description
Reproduction
I am trying to get the name of a MatInput
control which is bound to a component property name
as:
<input matInput [name]="name" [(ngModel)]="model">
I am using the getName()
method of MatInputHarness
as:
const input = await loader.getHarness(MatInputHarness);
expect(await input.getName()).not.toBe('')
but the expectation fails. If I remove the ngModel
directive, the test passes successfully.
https://stackblitz.com/edit/components-issue-atwks1
Expected Behavior
The test should pass
Actual Behavior
The test fails
Environment
- Angular: 9.0.2
- CDK/Material: 9.1.0
- Browser(s):
- Operating System (e.g. Windows, macOS, Ubuntu): Windows
Metadata
Metadata
Assignees
Labels
P3An issue that is relevant to core functions, but does not impede progress. Important, but not urgentAn issue that is relevant to core functions, but does not impede progress. Important, but not urgentarea: material/input