1 | /**
|
---|
2 | * @license
|
---|
3 | * Copyright Google LLC All Rights Reserved.
|
---|
4 | *
|
---|
5 | * Use of this source code is governed by an MIT-style license that can be
|
---|
6 | * found in the LICENSE file at https://angular.io/license
|
---|
7 | */
|
---|
8 | import { ComponentHarness, HarnessPredicate } from '@angular/cdk/testing';
|
---|
9 | import { OptionHarnessFilters } from './option-harness-filters';
|
---|
10 | /** Harness for interacting with a `mat-option` in tests. */
|
---|
11 | export declare class MatOptionHarness extends ComponentHarness {
|
---|
12 | /** Selector used to locate option instances. */
|
---|
13 | static hostSelector: string;
|
---|
14 | /** Element containing the option's text. */
|
---|
15 | private _text;
|
---|
16 | /**
|
---|
17 | * Gets a `HarnessPredicate` that can be used to search for a `MatOptionsHarness` that meets
|
---|
18 | * certain criteria.
|
---|
19 | * @param options Options for filtering which option instances are considered a match.
|
---|
20 | * @return a `HarnessPredicate` configured with the given options.
|
---|
21 | */
|
---|
22 | static with(options?: OptionHarnessFilters): HarnessPredicate<MatOptionHarness>;
|
---|
23 | /** Clicks the option. */
|
---|
24 | click(): Promise<void>;
|
---|
25 | /** Gets the option's label text. */
|
---|
26 | getText(): Promise<string>;
|
---|
27 | /** Gets whether the option is disabled. */
|
---|
28 | isDisabled(): Promise<boolean>;
|
---|
29 | /** Gets whether the option is selected. */
|
---|
30 | isSelected(): Promise<boolean>;
|
---|
31 | /** Gets whether the option is active. */
|
---|
32 | isActive(): Promise<boolean>;
|
---|
33 | /** Gets whether the option is in multiple selection mode. */
|
---|
34 | isMultiple(): Promise<boolean>;
|
---|
35 | }
|
---|