source: trip-planner-front/node_modules/@angular/material/button-toggle/testing/button-toggle-harness.d.ts

Last change on this file was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 2.5 KB
Line 
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 */
8import { ComponentHarness, HarnessPredicate } from '@angular/cdk/testing';
9import { MatButtonToggleAppearance } from '@angular/material/button-toggle';
10import { ButtonToggleHarnessFilters } from './button-toggle-harness-filters';
11/** Harness for interacting with a standard mat-button-toggle in tests. */
12export declare class MatButtonToggleHarness extends ComponentHarness {
13 /** The selector for the host element of a `MatButton` instance. */
14 static hostSelector: string;
15 private _label;
16 private _button;
17 /**
18 * Gets a `HarnessPredicate` that can be used to search for a `MatButtonToggleHarness` that meets
19 * certain criteria.
20 * @param options Options for filtering which button toggle instances are considered a match.
21 * @return a `HarnessPredicate` configured with the given options.
22 */
23 static with(options?: ButtonToggleHarnessFilters): HarnessPredicate<MatButtonToggleHarness>;
24 /** Gets a boolean promise indicating if the button toggle is checked. */
25 isChecked(): Promise<boolean>;
26 /** Gets a boolean promise indicating if the button toggle is disabled. */
27 isDisabled(): Promise<boolean>;
28 /** Gets a promise for the button toggle's name. */
29 getName(): Promise<string | null>;
30 /** Gets a promise for the button toggle's aria-label. */
31 getAriaLabel(): Promise<string | null>;
32 /** Gets a promise for the button toggles's aria-labelledby. */
33 getAriaLabelledby(): Promise<string | null>;
34 /** Gets a promise for the button toggle's text. */
35 getText(): Promise<string>;
36 /** Gets the appearance that the button toggle is using. */
37 getAppearance(): Promise<MatButtonToggleAppearance>;
38 /** Focuses the toggle. */
39 focus(): Promise<void>;
40 /** Blurs the toggle. */
41 blur(): Promise<void>;
42 /** Whether the toggle is focused. */
43 isFocused(): Promise<boolean>;
44 /** Toggle the checked state of the buttons toggle. */
45 toggle(): Promise<void>;
46 /**
47 * Puts the button toggle in a checked state by toggling it if it's
48 * currently unchecked, or doing nothing if it is already checked.
49 */
50 check(): Promise<void>;
51 /**
52 * Puts the button toggle in an unchecked state by toggling it if it's
53 * currently checked, or doing nothing if it's already unchecked.
54 */
55 uncheck(): Promise<void>;
56}
Note: See TracBrowser for help on using the repository browser.