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 { MatBadgePosition, MatBadgeSize } from '@angular/material/badge';
|
---|
10 | import { BadgeHarnessFilters } from './badge-harness-filters';
|
---|
11 | /** Harness for interacting with a standard Material badge in tests. */
|
---|
12 | export declare class MatBadgeHarness extends ComponentHarness {
|
---|
13 | static hostSelector: string;
|
---|
14 | /**
|
---|
15 | * Gets a `HarnessPredicate` that can be used to search for a badge with specific attributes.
|
---|
16 | * @param options Options for narrowing the search:
|
---|
17 | * - `text` finds a badge host with a particular text.
|
---|
18 | * @return a `HarnessPredicate` configured with the given options.
|
---|
19 | */
|
---|
20 | static with(options?: BadgeHarnessFilters): HarnessPredicate<MatBadgeHarness>;
|
---|
21 | private _badgeElement;
|
---|
22 | /** Gets a promise for the badge text. */
|
---|
23 | getText(): Promise<string>;
|
---|
24 | /** Gets whether the badge is overlapping the content. */
|
---|
25 | isOverlapping(): Promise<boolean>;
|
---|
26 | /** Gets the position of the badge. */
|
---|
27 | getPosition(): Promise<MatBadgePosition>;
|
---|
28 | /** Gets the size of the badge. */
|
---|
29 | getSize(): Promise<MatBadgeSize>;
|
---|
30 | /** Gets whether the badge is hidden. */
|
---|
31 | isHidden(): Promise<boolean>;
|
---|
32 | /** Gets whether the badge is disabled. */
|
---|
33 | isDisabled(): Promise<boolean>;
|
---|
34 | }
|
---|