@coolon/angular-ui-powerups 12.4.0-alpha.18 → 12.4.0-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/styles.scss +0 -1
- package/bundles/coolon-angular-ui-powerups-cypress.umd.js +241 -520
- package/bundles/coolon-angular-ui-powerups-cypress.umd.js.map +1 -1
- package/bundles/coolon-angular-ui-powerups.umd.js +7 -2
- package/bundles/coolon-angular-ui-powerups.umd.js.map +1 -1
- package/coolon-angular-ui-powerups.metadata.json +1 -1
- package/cypress/components/aup-command-face.d.ts +4 -5
- package/cypress/components/aup-command.d.ts +1 -1
- package/cypress/components/aup-input.d.ts +5 -11
- package/cypress/components/aup-popup-menu.d.ts +2 -1
- package/cypress/components/aup-table.d.ts +3 -29
- package/cypress/components/{form-element-mixin.d.ts → button-mixin.d.ts} +6 -7
- package/cypress/components/button.d.ts +6 -8
- package/cypress/coolon-angular-ui-powerups-cypress.metadata.json +1 -1
- package/cypress/exports.d.ts +2 -11
- package/cypress/page-element.d.ts +9 -8
- package/cypress/page.d.ts +33 -5
- package/cypress/section.d.ts +51 -0
- package/esm2015/cypress/components/aup-command-face.js +6 -6
- package/esm2015/cypress/components/aup-command-face.js.map +1 -1
- package/esm2015/cypress/components/aup-command-face.metadata.json +1 -1
- package/esm2015/cypress/components/aup-command.js +4 -12
- package/esm2015/cypress/components/aup-command.js.map +1 -1
- package/esm2015/cypress/components/aup-command.metadata.json +1 -1
- package/esm2015/cypress/components/aup-input.js +5 -17
- package/esm2015/cypress/components/aup-input.js.map +1 -1
- package/esm2015/cypress/components/aup-input.metadata.json +1 -1
- package/esm2015/cypress/components/aup-navigation.js +1 -1
- package/esm2015/cypress/components/aup-navigation.js.map +1 -1
- package/esm2015/cypress/components/aup-popup-menu.js +3 -3
- package/esm2015/cypress/components/aup-popup-menu.js.map +1 -1
- package/esm2015/cypress/components/aup-popup-menu.metadata.json +1 -1
- package/esm2015/cypress/components/aup-table.js +7 -85
- package/esm2015/cypress/components/aup-table.js.map +1 -1
- package/esm2015/cypress/components/aup-table.metadata.json +1 -1
- package/esm2015/cypress/components/button-mixin.js +15 -0
- package/esm2015/cypress/components/button-mixin.js.map +1 -0
- package/esm2015/cypress/components/button-mixin.metadata.json +1 -0
- package/esm2015/cypress/components/button.js +10 -4
- package/esm2015/cypress/components/button.js.map +1 -1
- package/esm2015/cypress/components/button.metadata.json +1 -1
- package/esm2015/cypress/exports.js +2 -11
- package/esm2015/cypress/exports.js.map +1 -1
- package/esm2015/cypress/exports.metadata.json +1 -1
- package/esm2015/cypress/page-element.js +18 -21
- package/esm2015/cypress/page-element.js.map +1 -1
- package/esm2015/cypress/page-element.metadata.json +1 -1
- package/esm2015/cypress/page.js +10 -8
- package/esm2015/cypress/page.js.map +1 -1
- package/esm2015/cypress/page.metadata.json +1 -1
- package/esm2015/cypress/path.js +1 -3
- package/esm2015/cypress/path.js.map +1 -1
- package/esm2015/cypress/section.js +58 -0
- package/esm2015/cypress/section.js.map +1 -0
- package/esm2015/cypress/section.metadata.json +1 -0
- package/esm2015/lib/components/empty-state/empty-state.component.js +1 -1
- package/esm2015/lib/components/empty-state/empty-state.component.metadata.json +1 -1
- package/esm2015/lib/place/url-snapshot.js +7 -1
- package/esm2015/lib/place/url-snapshot.js.map +1 -1
- package/esm2015/lib/place/url-snapshot.metadata.json +1 -1
- package/fesm2015/coolon-angular-ui-powerups-cypress.js +168 -414
- package/fesm2015/coolon-angular-ui-powerups-cypress.js.map +1 -1
- package/fesm2015/coolon-angular-ui-powerups.js +7 -2
- package/fesm2015/coolon-angular-ui-powerups.js.map +1 -1
- package/package.json +1 -1
- package/assets/empty-state.scss +0 -11
- package/cypress/builder.d.ts +0 -39
- package/cypress/components/aup-abstract-activity.d.ts +0 -9
- package/cypress/components/aup-activity.d.ts +0 -9
- package/cypress/components/aup-alert.d.ts +0 -9
- package/cypress/components/aup-empty-state.d.ts +0 -4
- package/cypress/components/aup-modal-activity.d.ts +0 -4
- package/cypress/components/aup-modal-alert.d.ts +0 -7
- package/cypress/components/mat-checkbox.d.ts +0 -29
- package/cypress/element-locator.d.ts +0 -10
- package/cypress/page-builder.d.ts +0 -8
- package/esm2015/cypress/builder.js +0 -97
- package/esm2015/cypress/builder.js.map +0 -1
- package/esm2015/cypress/builder.metadata.json +0 -1
- package/esm2015/cypress/components/aup-abstract-activity.js +0 -12
- package/esm2015/cypress/components/aup-abstract-activity.js.map +0 -1
- package/esm2015/cypress/components/aup-abstract-activity.metadata.json +0 -1
- package/esm2015/cypress/components/aup-activity.js +0 -13
- package/esm2015/cypress/components/aup-activity.js.map +0 -1
- package/esm2015/cypress/components/aup-activity.metadata.json +0 -1
- package/esm2015/cypress/components/aup-alert.js +0 -13
- package/esm2015/cypress/components/aup-alert.js.map +0 -1
- package/esm2015/cypress/components/aup-alert.metadata.json +0 -1
- package/esm2015/cypress/components/aup-empty-state.js +0 -7
- package/esm2015/cypress/components/aup-empty-state.js.map +0 -1
- package/esm2015/cypress/components/aup-empty-state.metadata.json +0 -1
- package/esm2015/cypress/components/aup-modal-activity.js +0 -7
- package/esm2015/cypress/components/aup-modal-activity.js.map +0 -1
- package/esm2015/cypress/components/aup-modal-activity.metadata.json +0 -1
- package/esm2015/cypress/components/aup-modal-alert.js +0 -12
- package/esm2015/cypress/components/aup-modal-alert.js.map +0 -1
- package/esm2015/cypress/components/aup-modal-alert.metadata.json +0 -1
- package/esm2015/cypress/components/form-element-mixin.js +0 -11
- package/esm2015/cypress/components/form-element-mixin.js.map +0 -1
- package/esm2015/cypress/components/form-element-mixin.metadata.json +0 -1
- package/esm2015/cypress/components/mat-checkbox.js +0 -34
- package/esm2015/cypress/components/mat-checkbox.js.map +0 -1
- package/esm2015/cypress/components/mat-checkbox.metadata.json +0 -1
- package/esm2015/cypress/element-locator.js +0 -22
- package/esm2015/cypress/element-locator.js.map +0 -1
- package/esm2015/cypress/element-locator.metadata.json +0 -1
- package/esm2015/cypress/page-builder.js +0 -15
- package/esm2015/cypress/page-builder.js.map +0 -1
- package/esm2015/cypress/page-builder.metadata.json +0 -1
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
/// <reference types="cypress" />
|
|
2
|
-
import { ElementLocator } from '../element-locator';
|
|
3
2
|
import { PageElement } from '../page-element';
|
|
4
3
|
import { Types } from './types';
|
|
5
|
-
export declare class
|
|
4
|
+
export declare class FaceAccessor implements PageElement.Accessor {
|
|
6
5
|
readonly face: Types.CommandFace;
|
|
7
6
|
constructor(face: Types.CommandFace);
|
|
8
|
-
findIn(parent:
|
|
9
|
-
shouldNotExist(parent:
|
|
7
|
+
findIn(parent: Cypress.Chainable<JQuery>): Cypress.Chainable<JQuery>;
|
|
8
|
+
shouldNotExist(parent: Cypress.Chainable<JQuery>): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
10
9
|
}
|
|
11
10
|
export declare class AupCommandFace extends PageElement {
|
|
12
11
|
constructor(parentElement: PageElement, face: Types.CommandFace);
|
|
13
|
-
static
|
|
12
|
+
static createAccessor(face: Types.CommandFace): PageElement.Accessor;
|
|
14
13
|
}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import { PageElement } from '../page-element';
|
|
3
3
|
import { Types } from './types';
|
|
4
4
|
export declare class AupCommand extends PageElement {
|
|
5
|
-
constructor(parent: PageElement,
|
|
5
|
+
constructor(parent: PageElement | (() => Cypress.Chainable<JQuery>), face: Types.CommandFace);
|
|
6
6
|
click(): void;
|
|
7
7
|
getShouldElement(): Cypress.Chainable<JQuery>;
|
|
8
8
|
shouldBeDisabled(): void;
|
|
@@ -1,34 +1,28 @@
|
|
|
1
1
|
/// <reference types="cypress" />
|
|
2
2
|
import { PageElement } from '../page-element';
|
|
3
|
-
import Chainable = Cypress.Chainable;
|
|
4
3
|
export declare abstract class AupInput<T> extends PageElement {
|
|
5
|
-
label(): Chainable<JQuery<HTMLLabelElement>>;
|
|
6
|
-
hint(): Chainable<JQuery<HTMLElement>>;
|
|
7
|
-
error(): Chainable<JQuery<HTMLElement>>;
|
|
4
|
+
label(): Cypress.Chainable<JQuery<HTMLLabelElement>>;
|
|
5
|
+
hint(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
6
|
+
error(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
8
7
|
get labelShould(): any;
|
|
9
8
|
get hintShould(): any;
|
|
10
9
|
get errorShould(): any;
|
|
11
10
|
labelShouldBe(text: string): any;
|
|
12
11
|
hintShouldBe(text: string): any;
|
|
13
12
|
errorShouldBe(text: string): any;
|
|
14
|
-
shouldBeFocused(): void;
|
|
15
|
-
shouldNotBeFocused(): void;
|
|
16
|
-
type(characters: string): void;
|
|
17
|
-
hitEnter(): void;
|
|
18
|
-
abstract input(): Chainable<JQuery>;
|
|
19
13
|
abstract clear(): any;
|
|
20
14
|
abstract setValue(value: T): any;
|
|
21
15
|
}
|
|
22
16
|
export declare namespace AupInput {
|
|
23
17
|
class HtmlInput<T> extends AupInput<T> {
|
|
24
|
-
input(): Chainable<JQuery<HTMLInputElement>>;
|
|
18
|
+
input(): Cypress.Chainable<JQuery<HTMLInputElement>>;
|
|
25
19
|
clear(): void;
|
|
26
20
|
setValue(value: T): void;
|
|
27
21
|
getShouldElement(): Cypress.Chainable<JQuery>;
|
|
28
22
|
}
|
|
29
23
|
class TextAreaInput<T> extends AupInput<T> {
|
|
30
24
|
getShouldElement(): Cypress.Chainable<JQuery>;
|
|
31
|
-
input(): Chainable<JQuery<HTMLTextAreaElement>>;
|
|
25
|
+
input(): Cypress.Chainable<JQuery<HTMLTextAreaElement>>;
|
|
32
26
|
clear(): void;
|
|
33
27
|
setValue(value: T): void;
|
|
34
28
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
/// <reference types="cypress" />
|
|
1
2
|
import { PageElement } from '../page-element';
|
|
2
3
|
import { Types } from './types';
|
|
3
4
|
export declare class AupPopupMenu extends PageElement {
|
|
4
|
-
constructor(parentElementAccessor: PageElement, face: Types.CommandFace);
|
|
5
|
+
constructor(parentElementAccessor: PageElement | (() => Cypress.Chainable<JQuery>), face: Types.CommandFace);
|
|
5
6
|
static create(parent: PageElement, face: Types.CommandFace): AupPopupMenu;
|
|
6
7
|
}
|
|
@@ -1,45 +1,19 @@
|
|
|
1
1
|
/// <reference types="cypress" />
|
|
2
|
-
import { ElementLocator } from '../element-locator';
|
|
3
2
|
import { PageElement } from '../page-element';
|
|
4
3
|
export declare class AupTable extends PageElement {
|
|
4
|
+
constructor(parentElementAccessor: () => Cypress.Chainable<JQuery>, selector: string | PageElement.Accessor);
|
|
5
5
|
row(rowId: any): AupTable.Row;
|
|
6
|
-
rowNumber(rowNumber: number): AupTable.Row;
|
|
7
6
|
column(columnId: string): AupTable.Column;
|
|
8
|
-
selectionColumn(): AupTable.SelectionColumn;
|
|
9
7
|
}
|
|
10
8
|
export declare namespace AupTable {
|
|
11
|
-
import Chainable = Cypress.Chainable;
|
|
12
|
-
function cssSelectorForTableRowById(rowId: string): string;
|
|
13
|
-
function cssSelectorForNthTableRow(rowNumber: number): string;
|
|
14
|
-
function cssSelectorForColumnCellRendererById(columnId: string): string;
|
|
15
|
-
function cssSelectorForCell(rowId: string, columnId: string): string;
|
|
16
9
|
class Row extends PageElement {
|
|
17
|
-
readonly table: AupTable;
|
|
18
|
-
constructor(table: AupTable, selectorOrLocator: string | ElementLocator);
|
|
19
|
-
rowId(): Chainable<string>;
|
|
20
|
-
shouldHaveRowId(rowId: string): void;
|
|
21
|
-
cell(columnId: string): Cell;
|
|
22
|
-
cell(column: AupTable.Column): Cell;
|
|
23
|
-
cell(column: AupTable.SelectionColumn): SelectionColumnCell;
|
|
24
|
-
shouldBeSelected(): void;
|
|
25
|
-
shouldNotBeSelected(): void;
|
|
26
10
|
}
|
|
27
|
-
class Column
|
|
11
|
+
class Column {
|
|
28
12
|
readonly table: AupTable;
|
|
29
13
|
readonly columnId: string;
|
|
30
14
|
constructor(table: AupTable, columnId: string);
|
|
31
|
-
|
|
32
|
-
rowContaining(content: string): Row;
|
|
33
|
-
}
|
|
34
|
-
class SelectionColumn extends Column {
|
|
35
|
-
selectAll(): void;
|
|
15
|
+
cell(content: string): Cell;
|
|
36
16
|
}
|
|
37
17
|
class Cell extends PageElement {
|
|
38
|
-
readonly table: AupTable;
|
|
39
|
-
constructor(table: AupTable, elementLocator: ElementLocator);
|
|
40
|
-
rowId(): Chainable<string>;
|
|
41
|
-
row(): Row;
|
|
42
|
-
}
|
|
43
|
-
class SelectionColumnCell extends Cell {
|
|
44
18
|
}
|
|
45
19
|
}
|
|
@@ -1,20 +1,19 @@
|
|
|
1
1
|
/// <reference types="cypress" />
|
|
2
2
|
import { Constructable } from '@coolon/typescript-utilities';
|
|
3
3
|
import { PageElement } from '../page-element';
|
|
4
|
-
export declare function
|
|
4
|
+
export declare function ButtonMixin<T, BC extends Constructable<PageElement>>(Base: BC): {
|
|
5
5
|
new (...args: any[]): {
|
|
6
|
+
click(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
6
7
|
shouldBeDisabled(): void;
|
|
7
|
-
readonly elementAccessStrategy:
|
|
8
|
-
readonly
|
|
9
|
-
|
|
8
|
+
readonly elementAccessStrategy: PageElement.Accessor;
|
|
9
|
+
readonly parentElementAccessor: () => Cypress.Chainable<JQuery<HTMLElement>>;
|
|
10
|
+
element(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
11
|
+
getParentElement(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
10
12
|
find(selector: string): PageElement;
|
|
11
|
-
click(text?: string): void;
|
|
12
13
|
readonly should: any;
|
|
13
14
|
getShoulder(element: Cypress.Chainable<JQuery<HTMLElement>>): any;
|
|
14
15
|
getShouldElement(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
15
16
|
shouldBeVisible(): void;
|
|
16
17
|
shouldNotBeVisible(): void;
|
|
17
|
-
shouldExist(): void;
|
|
18
|
-
shouldNotExist(): void;
|
|
19
18
|
};
|
|
20
19
|
} & BC;
|
|
@@ -1,24 +1,22 @@
|
|
|
1
1
|
/// <reference types="cypress" />
|
|
2
|
-
import { ElementLocator } from '../element-locator';
|
|
3
2
|
import { PageElement } from '../page-element';
|
|
4
3
|
declare const Button_base: {
|
|
5
4
|
new (...args: any[]): {
|
|
5
|
+
click(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
6
6
|
shouldBeDisabled(): void;
|
|
7
|
-
readonly elementAccessStrategy:
|
|
8
|
-
readonly
|
|
9
|
-
|
|
7
|
+
readonly elementAccessStrategy: PageElement.Accessor;
|
|
8
|
+
readonly parentElementAccessor: () => Cypress.Chainable<JQuery<HTMLElement>>;
|
|
9
|
+
element(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
10
|
+
getParentElement(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
10
11
|
find(selector: string): PageElement;
|
|
11
|
-
click(text?: string): void;
|
|
12
12
|
readonly should: any;
|
|
13
13
|
getShoulder(element: Cypress.Chainable<JQuery<HTMLElement>>): any;
|
|
14
14
|
getShouldElement(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
15
15
|
shouldBeVisible(): void;
|
|
16
16
|
shouldNotBeVisible(): void;
|
|
17
|
-
shouldExist(): void;
|
|
18
|
-
shouldNotExist(): void;
|
|
19
17
|
};
|
|
20
18
|
} & typeof PageElement;
|
|
21
19
|
export declare class Button extends Button_base {
|
|
22
|
-
constructor(parentElementAccessor:
|
|
20
|
+
constructor(parentElementAccessor: () => Cypress.Chainable<JQuery>, buttonText: string);
|
|
23
21
|
}
|
|
24
22
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"__symbolic":"module","version":4,"exports":[{"from":"./components/types"}],"metadata":{"Builder":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"PageElement"}]}],"find":[{"__symbolic":"method"}],"section":[{"__symbolic":"method"}],"contains":[{"__symbolic":"method"}],"button":[{"__symbolic":"method"}],"matCheckbox":[{"__symbolic":"method"}],"aupStringInput":[{"__symbolic":"method"}],"aupTextInput":[{"__symbolic":"method"}],"aupPasswordInput":[{"__symbolic":"method"}],"aupNumberInput":[{"__symbolic":"method"}],"aupCommand":[{"__symbolic":"method"},{"__symbolic":"method"},{"__symbolic":"method"}],"aupTabbedNavigation":[{"__symbolic":"method"}],"aupSideNavigation":[{"__symbolic":"method"}],"aupTable":[{"__symbolic":"method"},{"__symbolic":"method"},{"__symbolic":"method"},{"__symbolic":"method"}],"aupEmptyState":[{"__symbolic":"method"},{"__symbolic":"method"},{"__symbolic":"method"},{"__symbolic":"method"}],"createElement":[{"__symbolic":"method"}],"createContainerElement":[{"__symbolic":"method"}]}},"ElementLocator":{"__symbolic":"interface"},"PageBuilder":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"Builder"},"members":{"aupModalActivity":[{"__symbolic":"method"}],"aupModalAlert":[{"__symbolic":"method"}],"aupModelConfirm":[{"__symbolic":"method"}]}},"PageElement":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"PageElement"},{"__symbolic":"reference","name":"string"}]},{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"PageElement"},{"__symbolic":"reference","name":"ElementLocator"}]},{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"PageElement"},{"__symbolic":"reference","name":"string"}]}],"dom":[{"__symbolic":"method"}],"find":[{"__symbolic":"method"}],"click":[{"__symbolic":"method"}],"getShoulder":[{"__symbolic":"method"}],"getShouldElement":[{"__symbolic":"method"}],"shouldBeVisible":[{"__symbolic":"method"}],"shouldNotBeVisible":[{"__symbolic":"method"}],"shouldExist":[{"__symbolic":"method"}],"shouldNotExist":[{"__symbolic":"method"}]}},"Page":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"Path"}]}],"dom":[{"__symbolic":"method"}],"visit":[{"__symbolic":"method"}],"tryAndVisit":[{"__symbolic":"method"}],"shouldHaveActivityIds":[{"__symbolic":"method"}],"shouldNotHaveActivityIds":[{"__symbolic":"method"}],"shouldHaveTitle":[{"__symbolic":"method"}],"shouldBeActive":[{"__symbolic":"method"}]}},"Path":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"Array","arguments":[{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Path"},"member":"Segment"}]}]}],"toUrl":[{"__symbolic":"method"}]}},"AupAbstractActivity":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"PageElement"},{"__symbolic":"reference","name":"string"}]}]}},"AupActivity":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"AupAbstractActivity"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"PageElement"},{"__symbolic":"reference","name":"string"}]}]}},"AupAlert":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"AupAbstractActivity"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"PageElement"},{"__symbolic":"reference","name":"string"}]}],"clickClose":[{"__symbolic":"method"}]}},"FaceElementLocator":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"select","expression":{"__symbolic":"reference","name":"ɵa"},"member":"CommandFace"}]}],"findIn":[{"__symbolic":"method"}],"shouldNotExist":[{"__symbolic":"method"}]}},"AupCommandFace":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"PageElement"},{"__symbolic":"select","expression":{"__symbolic":"reference","name":"ɵa"},"member":"CommandFace"}]}]},"statics":{"createElementLocator":{"__symbolic":"function","parameters":["face"],"value":{"__symbolic":"new","expression":{"__symbolic":"reference","name":"FaceElementLocator"},"arguments":[{"__symbolic":"reference","name":"face"}]}}}},"AupCommandGroup":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{}},"AupCommand":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"PageElement"},{"__symbolic":"select","expression":{"__symbolic":"reference","name":"ɵa"},"member":"CommandFace"}]}],"click":[{"__symbolic":"method"}],"getShouldElement":[{"__symbolic":"method"}],"shouldBeDisabled":[{"__symbolic":"method"}],"getButton":[{"__symbolic":"method"}]}},"AupEmptyState":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{"shouldContainText":[{"__symbolic":"method"}]}},"AupInput":{"__symbolic":"class","arity":1,"extends":{"__symbolic":"reference","name":"PageElement"},"members":{"label":[{"__symbolic":"method"}],"hint":[{"__symbolic":"method"}],"error":[{"__symbolic":"method"}],"labelShouldBe":[{"__symbolic":"method"}],"hintShouldBe":[{"__symbolic":"method"}],"errorShouldBe":[{"__symbolic":"method"}],"shouldBeFocused":[{"__symbolic":"method"}],"shouldNotBeFocused":[{"__symbolic":"method"}],"type":[{"__symbolic":"method"}],"hitEnter":[{"__symbolic":"method"}],"input":[{"__symbolic":"method"}],"clear":[{"__symbolic":"method"}],"setValue":[{"__symbolic":"method"}]}},"AupModalActivity":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"AupActivity"},"members":{"clickBackdrop":[{"__symbolic":"method"}]}},"AupModalAlert":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"AupAlert"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"PageElement"},{"__symbolic":"reference","name":"string"}]}],"clickBackdrop":[{"__symbolic":"method"}]}},"AupMoreMenu":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{},"statics":{"create":{"__symbolic":"function","parameters":["parent"],"value":{"__symbolic":"new","expression":{"__symbolic":"reference","name":"AupMoreMenu"},"arguments":[{"__symbolic":"reference","name":"parent"},"aup-more-menu"]}}}},"AupNavigation":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{"click":[{"__symbolic":"method"}],"face":[{"__symbolic":"method"}],"shouldHaveLink":[{"__symbolic":"method"}],"shouldNotHaveLink":[{"__symbolic":"method"}]}},"AupPopupMenu":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"PageElement"},{"__symbolic":"select","expression":{"__symbolic":"reference","name":"ɵa"},"member":"CommandFace"}]}]},"statics":{"create":{"__symbolic":"function","parameters":["parent","face"],"value":{"__symbolic":"new","expression":{"__symbolic":"reference","name":"AupPopupMenu"},"arguments":[{"__symbolic":"reference","name":"parent"},{"__symbolic":"reference","name":"face"}]}}}},"AupTable":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{"row":[{"__symbolic":"method"}],"rowNumber":[{"__symbolic":"method"}],"column":[{"__symbolic":"method"}],"selectionColumn":[{"__symbolic":"method"}]}},"AupToolBar":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{}},"Button":{"__symbolic":"class","extends":{"__symbolic":"error","message":"Symbol reference expected","line":4,"character":28,"module":"./components/button"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"PageElement"},{"__symbolic":"reference","name":"string"}]}]}},"FormElementMixin":{"__symbolic":"function","parameters":["Base"],"value":{"__symbolic":"class"}},"MatCheckbox":{"__symbolic":"class","extends":{"__symbolic":"error","message":"Symbol reference expected","line":4,"character":33,"module":"./components/mat-checkbox"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"PageElement"},{"__symbolic":"reference","name":"string"}]}],"shouldBeChecked":[{"__symbolic":"method"}],"shouldNotBeChecked":[{"__symbolic":"method"}],"hiddenCheckBoxElement":[{"__symbolic":"method"}],"check":[{"__symbolic":"method"}],"uncheck":[{"__symbolic":"method"}]}}},"origins":{"Builder":"./builder","ElementLocator":"./element-locator","PageBuilder":"./page-builder","PageElement":"./page-element","Page":"./page","Path":"./path","AupAbstractActivity":"./components/aup-abstract-activity","AupActivity":"./components/aup-activity","AupAlert":"./components/aup-alert","FaceElementLocator":"./components/aup-command-face","AupCommandFace":"./components/aup-command-face","AupCommandGroup":"./components/aup-command-group","AupCommand":"./components/aup-command","AupEmptyState":"./components/aup-empty-state","AupInput":"./components/aup-input","AupModalActivity":"./components/aup-modal-activity","AupModalAlert":"./components/aup-modal-alert","AupMoreMenu":"./components/aup-more-menu","AupNavigation":"./components/aup-navigation","AupPopupMenu":"./components/aup-popup-menu","AupTable":"./components/aup-table","AupToolBar":"./components/aup-tool-bar","Button":"./components/button","FormElementMixin":"./components/form-element-mixin","MatCheckbox":"./components/mat-checkbox","ɵa":"./components/types"},"importAs":"@coolon/angular-ui-powerups/cypress"}
|
|
1
|
+
{"__symbolic":"module","version":4,"exports":[{"from":"./components/types"}],"metadata":{"PageElement":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"error","message":"Expression form not supported","line":9,"character":36,"module":"./page-element"},{"__symbolic":"select","expression":{"__symbolic":"reference","name":"PageElement"},"member":"Accessor"}]}],"element":[{"__symbolic":"method"}],"getParentElement":[{"__symbolic":"method"}],"find":[{"__symbolic":"method"}],"click":[{"__symbolic":"method"}],"getShoulder":[{"__symbolic":"method"}],"getShouldElement":[{"__symbolic":"method"}],"shouldBeVisible":[{"__symbolic":"method"}],"shouldNotBeVisible":[{"__symbolic":"method"}]}},"Page":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"Path"}]}],"element":[{"__symbolic":"method"}],"visit":[{"__symbolic":"method"}],"tryAndVisit":[{"__symbolic":"method"}],"shouldHaveActivityIds":[{"__symbolic":"method"}],"shouldNotHaveActivityIds":[{"__symbolic":"method"}],"shouldHaveTitle":[{"__symbolic":"method"}],"shouldBeActive":[{"__symbolic":"method"}]}},"Path":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"Array","arguments":[{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Path"},"member":"Segment"}]}]}],"toUrl":[{"__symbolic":"method"}]}},"Section":{"__symbolic":"interface"},"FaceAccessor":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"select","expression":{"__symbolic":"reference","name":"ɵa"},"member":"CommandFace"}]}],"findIn":[{"__symbolic":"method"}],"shouldNotExist":[{"__symbolic":"method"}]}},"AupCommandFace":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"PageElement"},{"__symbolic":"select","expression":{"__symbolic":"reference","name":"ɵa"},"member":"CommandFace"}]}]},"statics":{"createAccessor":{"__symbolic":"function","parameters":["face"],"value":{"__symbolic":"new","expression":{"__symbolic":"reference","name":"FaceAccessor"},"arguments":[{"__symbolic":"reference","name":"face"}]}}}},"AupCommandGroup":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{}},"AupCommand":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"error","message":"Expression form not supported","line":6,"character":36,"module":"./components/aup-command"},{"__symbolic":"select","expression":{"__symbolic":"reference","name":"ɵa"},"member":"CommandFace"}]}],"click":[{"__symbolic":"method"}],"getShouldElement":[{"__symbolic":"method"}],"shouldBeDisabled":[{"__symbolic":"method"}],"getButton":[{"__symbolic":"method"}]}},"AupInput":{"__symbolic":"class","arity":1,"extends":{"__symbolic":"reference","name":"PageElement"},"members":{"label":[{"__symbolic":"method"}],"hint":[{"__symbolic":"method"}],"error":[{"__symbolic":"method"}],"labelShouldBe":[{"__symbolic":"method"}],"hintShouldBe":[{"__symbolic":"method"}],"errorShouldBe":[{"__symbolic":"method"}],"clear":[{"__symbolic":"method"}],"setValue":[{"__symbolic":"method"}]}},"AupMoreMenu":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{},"statics":{"create":{"__symbolic":"function","parameters":["parent"],"value":{"__symbolic":"new","expression":{"__symbolic":"reference","name":"AupMoreMenu"},"arguments":[{"__symbolic":"reference","name":"parent"},"aup-more-menu"]}}}},"AupNavigation":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{"click":[{"__symbolic":"method"}],"face":[{"__symbolic":"method"}],"shouldHaveLink":[{"__symbolic":"method"}],"shouldNotHaveLink":[{"__symbolic":"method"}]}},"AupPopupMenu":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"error","message":"Expression form not supported","line":7,"character":51,"module":"./components/aup-popup-menu"},{"__symbolic":"select","expression":{"__symbolic":"reference","name":"ɵa"},"member":"CommandFace"}]}]},"statics":{"create":{"__symbolic":"function","parameters":["parent","face"],"value":{"__symbolic":"new","expression":{"__symbolic":"reference","name":"AupPopupMenu"},"arguments":[{"__symbolic":"reference","name":"parent"},{"__symbolic":"reference","name":"face"}]}}}},"AupTable":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"error","message":"Expression form not supported","line":5,"character":37,"module":"./components/aup-table"},{"__symbolic":"select","expression":{"__symbolic":"reference","name":"PageElement"},"member":"Accessor"}]}],"row":[{"__symbolic":"method"}],"column":[{"__symbolic":"method"}]}},"AupToolBar":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"PageElement"},"members":{}},"ButtonMixin":{"__symbolic":"function","parameters":["Base"],"value":{"__symbolic":"class"}},"Button":{"__symbolic":"class","extends":{"__symbolic":"error","message":"Symbol reference expected","line":3,"character":28,"module":"./components/button"},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"error","message":"Expression form not supported","line":5,"character":37,"module":"./components/button"},{"__symbolic":"reference","name":"string"}]}]}}},"origins":{"PageElement":"./page-element","Page":"./page","Path":"./path","Section":"./section","FaceAccessor":"./components/aup-command-face","AupCommandFace":"./components/aup-command-face","AupCommandGroup":"./components/aup-command-group","AupCommand":"./components/aup-command","AupInput":"./components/aup-input","AupMoreMenu":"./components/aup-more-menu","AupNavigation":"./components/aup-navigation","AupPopupMenu":"./components/aup-popup-menu","AupTable":"./components/aup-table","AupToolBar":"./components/aup-tool-bar","ButtonMixin":"./components/button-mixin","Button":"./components/button","ɵa":"./components/types"},"importAs":"@coolon/angular-ui-powerups/cypress"}
|
package/cypress/exports.d.ts
CHANGED
|
@@ -1,28 +1,19 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @file Automatically generated by barrelsby.
|
|
3
3
|
*/
|
|
4
|
-
export * from "./builder";
|
|
5
|
-
export * from "./element-locator";
|
|
6
|
-
export * from "./page-builder";
|
|
7
4
|
export * from "./page-element";
|
|
8
5
|
export * from "./page";
|
|
9
6
|
export * from "./path";
|
|
10
|
-
export * from "./
|
|
11
|
-
export * from "./components/aup-activity";
|
|
12
|
-
export * from "./components/aup-alert";
|
|
7
|
+
export * from "./section";
|
|
13
8
|
export * from "./components/aup-command-face";
|
|
14
9
|
export * from "./components/aup-command-group";
|
|
15
10
|
export * from "./components/aup-command";
|
|
16
|
-
export * from "./components/aup-empty-state";
|
|
17
11
|
export * from "./components/aup-input";
|
|
18
|
-
export * from "./components/aup-modal-activity";
|
|
19
|
-
export * from "./components/aup-modal-alert";
|
|
20
12
|
export * from "./components/aup-more-menu";
|
|
21
13
|
export * from "./components/aup-navigation";
|
|
22
14
|
export * from "./components/aup-popup-menu";
|
|
23
15
|
export * from "./components/aup-table";
|
|
24
16
|
export * from "./components/aup-tool-bar";
|
|
17
|
+
export * from "./components/button-mixin";
|
|
25
18
|
export * from "./components/button";
|
|
26
|
-
export * from "./components/form-element-mixin";
|
|
27
|
-
export * from "./components/mat-checkbox";
|
|
28
19
|
export * from "./components/types";
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
/// <reference types="cypress" />
|
|
2
2
|
import Chainable = Cypress.Chainable;
|
|
3
|
-
import { ElementLocator } from './element-locator';
|
|
4
3
|
export declare class PageElement {
|
|
5
|
-
readonly
|
|
6
|
-
readonly
|
|
7
|
-
constructor(parent: PageElement, selector: string);
|
|
8
|
-
|
|
9
|
-
|
|
4
|
+
readonly elementAccessStrategy: PageElement.Accessor;
|
|
5
|
+
readonly parentElementAccessor: () => Cypress.Chainable<JQuery>;
|
|
6
|
+
constructor(parent: PageElement | (() => Cypress.Chainable<JQuery>), selector: string | PageElement.Accessor);
|
|
7
|
+
element(): Chainable<JQuery>;
|
|
8
|
+
getParentElement(): Cypress.Chainable<JQuery>;
|
|
10
9
|
find(selector: string): PageElement;
|
|
11
10
|
click(text?: string): void;
|
|
12
11
|
get should(): any;
|
|
@@ -14,8 +13,10 @@ export declare class PageElement {
|
|
|
14
13
|
getShouldElement(): Chainable<JQuery>;
|
|
15
14
|
shouldBeVisible(): void;
|
|
16
15
|
shouldNotBeVisible(): void;
|
|
17
|
-
shouldExist(): void;
|
|
18
|
-
shouldNotExist(): void;
|
|
19
16
|
}
|
|
20
17
|
export declare namespace PageElement {
|
|
18
|
+
interface Accessor {
|
|
19
|
+
findIn(parent: Cypress.Chainable<JQuery>): Cypress.Chainable<JQuery>;
|
|
20
|
+
shouldNotExist?(parent: Cypress.Chainable<JQuery>): any;
|
|
21
|
+
}
|
|
21
22
|
}
|
package/cypress/page.d.ts
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
/// <reference types="cypress" />
|
|
2
|
-
import { Builder } from './builder';
|
|
3
|
-
import { PageBuilder } from './page-builder';
|
|
4
2
|
import { PageElement } from './page-element';
|
|
5
3
|
import { Path } from './path';
|
|
4
|
+
import { Section } from './section';
|
|
6
5
|
export declare class Page extends PageElement {
|
|
7
6
|
readonly path: Path;
|
|
8
7
|
protected rootElementSelector: string;
|
|
9
8
|
constructor(path: Path);
|
|
10
|
-
|
|
9
|
+
element(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
11
10
|
visit(visitParams?: object, queryParams?: {
|
|
12
11
|
[key: string]: string;
|
|
13
12
|
}): void;
|
|
@@ -20,6 +19,35 @@ export declare class Page extends PageElement {
|
|
|
20
19
|
shouldBeActive(withParameters?: object): void;
|
|
21
20
|
}
|
|
22
21
|
export declare namespace Page {
|
|
23
|
-
function create<T extends object>(path: string,
|
|
24
|
-
function create<T extends object>(pathBuilder: ((pathBuilder: Path.Builder) => void),
|
|
22
|
+
export function create<T extends object>(path: string, page: (page: PageBuilder) => T): T & Page;
|
|
23
|
+
export function create<T extends object>(pathBuilder: ((pathBuilder: Path.Builder) => void), page: (page: PageBuilder) => T): T & Page;
|
|
24
|
+
const PageBuilder_base: {
|
|
25
|
+
new (...args: any[]): {
|
|
26
|
+
section<T extends object>(selector: string, section: (section: Section) => T): T & PageElement;
|
|
27
|
+
find(selector: string): PageElement;
|
|
28
|
+
contains(text: string): PageElement;
|
|
29
|
+
button(text: string): import("./exports").Button;
|
|
30
|
+
aupStringInput(selector?: string): import("./exports").AupInput<string>;
|
|
31
|
+
aupTextInput(selector?: string): import("./exports").AupInput<string>;
|
|
32
|
+
aupPasswordInput(selector?: string): import("./exports").AupInput<string>;
|
|
33
|
+
aupNumberInput(selector?: string): import("./exports").AupInput<number>;
|
|
34
|
+
aupCommand(face: import("./exports").Types.CommandFace): import("./exports").AupCommand;
|
|
35
|
+
aupTabbedNavigation<T_1 extends object>(): import("./exports").AupNavigation;
|
|
36
|
+
aupSideNavigation<T_2 extends object>(): import("./exports").AupNavigation;
|
|
37
|
+
aupTable(selector?: string): import("./exports").AupTable;
|
|
38
|
+
readonly elementAccessStrategy: PageElement.Accessor;
|
|
39
|
+
readonly parentElementAccessor: () => Cypress.Chainable<JQuery<HTMLElement>>;
|
|
40
|
+
element(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
41
|
+
getParentElement(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
42
|
+
click(text?: string): void;
|
|
43
|
+
readonly should: any;
|
|
44
|
+
getShoulder(element: Cypress.Chainable<JQuery<HTMLElement>>): any;
|
|
45
|
+
getShouldElement(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
46
|
+
shouldBeVisible(): void;
|
|
47
|
+
shouldNotBeVisible(): void;
|
|
48
|
+
};
|
|
49
|
+
} & typeof Page;
|
|
50
|
+
export class PageBuilder extends PageBuilder_base {
|
|
51
|
+
}
|
|
52
|
+
export {};
|
|
25
53
|
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/// <reference types="cypress" />
|
|
2
|
+
import { Constructable } from '@coolon/pectin';
|
|
3
|
+
import { AupCommand } from './components/aup-command';
|
|
4
|
+
import { AupInput } from './components/aup-input';
|
|
5
|
+
import { AupNavigation } from './components/aup-navigation';
|
|
6
|
+
import { AupTable } from './components/aup-table';
|
|
7
|
+
import { Button } from './components/button';
|
|
8
|
+
import { Types } from './components/types';
|
|
9
|
+
import { PageElement } from './page-element';
|
|
10
|
+
export interface Section {
|
|
11
|
+
section<T extends object>(selector: string, section: (section: Section) => T): T & PageElement;
|
|
12
|
+
find(selector: string): PageElement;
|
|
13
|
+
contains(text: string): PageElement;
|
|
14
|
+
button(text: string): Button;
|
|
15
|
+
aupStringInput(selector?: string): AupInput<string>;
|
|
16
|
+
aupTextInput(selector?: string): AupInput<string>;
|
|
17
|
+
aupPasswordInput(selector?: string): AupInput<string>;
|
|
18
|
+
aupNumberInput(selector?: string): AupInput<number>;
|
|
19
|
+
aupCommand(face: Types.CommandFace): AupCommand;
|
|
20
|
+
aupTabbedNavigation<T extends object>(): AupNavigation;
|
|
21
|
+
aupSideNavigation<T extends object>(): AupNavigation;
|
|
22
|
+
aupTable(selector?: string): AupTable;
|
|
23
|
+
}
|
|
24
|
+
export declare namespace Section {
|
|
25
|
+
function Mixin<BC extends Constructable<PageElement>>(Base: BC): {
|
|
26
|
+
new (...args: any[]): {
|
|
27
|
+
section<T extends object>(selector: string, section: (section: Section) => T): T & PageElement;
|
|
28
|
+
find(selector: string): PageElement;
|
|
29
|
+
contains(text: string): PageElement;
|
|
30
|
+
button(text: string): Button;
|
|
31
|
+
aupStringInput(selector?: string): AupInput<string>;
|
|
32
|
+
aupTextInput(selector?: string): AupInput<string>;
|
|
33
|
+
aupPasswordInput(selector?: string): AupInput<string>;
|
|
34
|
+
aupNumberInput(selector?: string): AupInput<number>;
|
|
35
|
+
aupCommand(face: Types.CommandFace): AupCommand;
|
|
36
|
+
aupTabbedNavigation<T_2 extends object>(): AupNavigation;
|
|
37
|
+
aupSideNavigation<T_3 extends object>(): AupNavigation;
|
|
38
|
+
aupTable(selector?: string): AupTable;
|
|
39
|
+
readonly elementAccessStrategy: PageElement.Accessor;
|
|
40
|
+
readonly parentElementAccessor: () => Cypress.Chainable<JQuery<HTMLElement>>;
|
|
41
|
+
element(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
42
|
+
getParentElement(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
43
|
+
click(text?: string): void;
|
|
44
|
+
readonly should: any;
|
|
45
|
+
getShoulder(element: Cypress.Chainable<JQuery<HTMLElement>>): any;
|
|
46
|
+
getShouldElement(): Cypress.Chainable<JQuery<HTMLElement>>;
|
|
47
|
+
shouldBeVisible(): void;
|
|
48
|
+
shouldNotBeVisible(): void;
|
|
49
|
+
};
|
|
50
|
+
} & BC;
|
|
51
|
+
}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { PageElement } from '../page-element';
|
|
2
|
-
export class
|
|
2
|
+
export class FaceAccessor {
|
|
3
3
|
constructor(face) {
|
|
4
4
|
this.face = face;
|
|
5
5
|
}
|
|
6
6
|
findIn(parent) {
|
|
7
7
|
return this.face.text ?
|
|
8
|
-
parent.
|
|
8
|
+
parent.contains(`aup-command-face`, this.face.text()) :
|
|
9
9
|
this.face.icon ?
|
|
10
|
-
parent.
|
|
10
|
+
parent.find(`aup-icon[ng-reflect-icon=${this.face.icon()}]`).closest('aup-command-face') :
|
|
11
11
|
undefined;
|
|
12
12
|
}
|
|
13
13
|
shouldNotExist(parent) {
|
|
@@ -20,10 +20,10 @@ export class FaceElementLocator {
|
|
|
20
20
|
}
|
|
21
21
|
export class AupCommandFace extends PageElement {
|
|
22
22
|
constructor(parentElement, face) {
|
|
23
|
-
super(parentElement, AupCommandFace.
|
|
23
|
+
super(() => parentElement.element(), AupCommandFace.createAccessor(face));
|
|
24
24
|
}
|
|
25
|
-
static
|
|
26
|
-
return new
|
|
25
|
+
static createAccessor(face) {
|
|
26
|
+
return new FaceAccessor(face);
|
|
27
27
|
}
|
|
28
28
|
}
|
|
29
29
|
//# sourceMappingURL=aup-command-face.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"aup-command-face.js","sourceRoot":"","sources":["../../../../../../libs/angular-ui-powerups/cypress/src/components/aup-command-face.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"aup-command-face.js","sourceRoot":"","sources":["../../../../../../libs/angular-ui-powerups/cypress/src/components/aup-command-face.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAG9C,MAAM,OAAO,YAAY;IACvB,YAAqB,IAAuB;QAAvB,SAAI,GAAJ,IAAI,CAAmB;IAC5C,CAAC;IACD,MAAM,CAAC,MAAiC;QACtC,OAAO,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;YACrB,MAAM,CAAC,QAAQ,CAAC,kBAAkB,EAAE,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC;YACvD,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;gBACd,MAAM,CAAC,IAAI,CAAC,4BAA4B,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC,OAAO,CAAC,kBAAkB,CAAC,CAAC,CAAC;gBAC1F,SAAS,CAAC;IAChB,CAAC;IACD,cAAc,CAAC,MAAiC;QAC9C,OAAO,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;YACrB,MAAM,CAAC,MAAM,CAAC,aAAa,EAAE,kBAAkB,EAAE,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC;YACpE,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;gBACd,MAAM,CAAC,MAAM,CAAC,aAAa,EAAE,4BAA4B,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC,CAAC;gBAC/E,SAAS,CAAC;IAChB,CAAC;CACF;AAED,MAAM,OAAO,cAAe,SAAQ,WAAW;IAE7C,YAAY,aAA0B,EAAE,IAAuB;QAC7D,KAAK,CAAC,GAAG,EAAE,CAAC,aAAa,CAAC,OAAO,EAAE,EAAE,cAAc,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC,CAAC;IAC5E,CAAC;IAED,MAAM,CAAC,cAAc,CAAC,IAAuB;QAC3C,OAAO,IAAI,YAAY,CAAC,IAAI,CAAC,CAAC;IAChC,CAAC;CACF","sourcesContent":["import { PageElement } from '../page-element';\nimport { Types } from './types';\n\nexport class FaceAccessor implements PageElement.Accessor{\n constructor(readonly face: Types.CommandFace) {\n }\n findIn(parent: Cypress.Chainable<JQuery>): Cypress.Chainable<JQuery> {\n return this.face.text ?\n parent.contains(`aup-command-face`, this.face.text()) :\n this.face.icon ?\n parent.find(`aup-icon[ng-reflect-icon=${this.face.icon()}]`).closest('aup-command-face') :\n undefined;\n }\n shouldNotExist(parent: Cypress.Chainable<JQuery>) {\n return this.face.text ?\n parent.should('not.contain', `aup-command-face`, this.face.text()) :\n this.face.icon ?\n parent.should('not.contain', `aup-icon[ng-reflect-icon=${this.face.icon()}]`) :\n undefined;\n }\n}\n\nexport class AupCommandFace extends PageElement {\n\n constructor(parentElement: PageElement, face: Types.CommandFace) {\n super(() => parentElement.element(), AupCommandFace.createAccessor(face));\n }\n\n static createAccessor(face: Types.CommandFace): PageElement.Accessor {\n return new FaceAccessor(face);\n }\n}\n\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
[{"__symbolic":"module","version":4,"metadata":{"
|
|
1
|
+
[{"__symbolic":"module","version":4,"metadata":{"FaceAccessor":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"select","expression":{"__symbolic":"reference","module":"./types","name":"Types","line":4,"character":29},"member":"CommandFace"}]}],"findIn":[{"__symbolic":"method"}],"shouldNotExist":[{"__symbolic":"method"}]}},"AupCommandFace":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"../page-element","name":"PageElement","line":22,"character":36},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"../page-element","name":"PageElement","line":24,"character":29},{"__symbolic":"select","expression":{"__symbolic":"reference","module":"./types","name":"Types","line":24,"character":48},"member":"CommandFace"}]}]},"statics":{"createAccessor":{"__symbolic":"function","parameters":["face"],"value":{"__symbolic":"new","expression":{"__symbolic":"reference","name":"FaceAccessor"},"arguments":[{"__symbolic":"reference","name":"face"}]}}}}}}]
|
|
@@ -1,19 +1,11 @@
|
|
|
1
1
|
import { PageElement } from '../page-element';
|
|
2
2
|
import { AupCommandFace } from './aup-command-face';
|
|
3
|
-
import * as _ from 'lodash';
|
|
4
3
|
export class AupCommand extends PageElement {
|
|
5
|
-
constructor(parent,
|
|
4
|
+
constructor(parent, face) {
|
|
5
|
+
const faceAccessor = AupCommandFace.createAccessor(face);
|
|
6
6
|
super(parent, {
|
|
7
7
|
findIn(parentElement) {
|
|
8
|
-
|
|
9
|
-
return parentElement.dom().find(faceOrSelector);
|
|
10
|
-
}
|
|
11
|
-
else {
|
|
12
|
-
return AupCommandFace.createElementLocator(faceOrSelector).findIn(parentElement).closest('aup-command');
|
|
13
|
-
}
|
|
14
|
-
},
|
|
15
|
-
shouldNotExist(parentElement) {
|
|
16
|
-
this.findIn(parentElement).should("not.exist");
|
|
8
|
+
return faceAccessor.findIn(parentElement).closest('aup-command');
|
|
17
9
|
}
|
|
18
10
|
});
|
|
19
11
|
}
|
|
@@ -27,7 +19,7 @@ export class AupCommand extends PageElement {
|
|
|
27
19
|
this.getButton().should('be.disabled');
|
|
28
20
|
}
|
|
29
21
|
getButton() {
|
|
30
|
-
return this.
|
|
22
|
+
return this.element().find('button');
|
|
31
23
|
}
|
|
32
24
|
}
|
|
33
25
|
//# sourceMappingURL=aup-command.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"aup-command.js","sourceRoot":"","sources":["../../../../../../libs/angular-ui-powerups/cypress/src/components/aup-command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAC9C,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"aup-command.js","sourceRoot":"","sources":["../../../../../../libs/angular-ui-powerups/cypress/src/components/aup-command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAC9C,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAGpD,MAAM,OAAO,UAAW,SAAQ,WAAW;IAEzC,YAAY,MAAuD,EAAE,IAAuB;QAC1F,MAAM,YAAY,GAAG,cAAc,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC;QACzD,KAAK,CAAC,MAAM,EAAE;YACZ,MAAM,CAAC,aAAwC;gBAC7C,OAAO,YAAY,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC,OAAO,CAAC,aAAa,CAAC,CAAC;YACnE,CAAC;SACF,CAAC,CAAC;IACL,CAAC;IAED,KAAK;QACH,IAAI,CAAC,SAAS,EAAE,CAAC,KAAK,EAAE,CAAC;IAC3B,CAAC;IAED,gBAAgB;QACd,OAAO,IAAI,CAAC,SAAS,EAAE,CAAC;IAC1B,CAAC;IAED,gBAAgB;QACd,IAAI,CAAC,SAAS,EAAE,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC;IACzC,CAAC;IAEO,SAAS;QACf,OAAO,IAAI,CAAC,OAAO,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;IACvC,CAAC;CAEF","sourcesContent":["import { PageElement } from '../page-element';\nimport { AupCommandFace } from './aup-command-face';\nimport { Types } from './types';\n\nexport class AupCommand extends PageElement {\n\n constructor(parent: PageElement | (() => Cypress.Chainable<JQuery>), face: Types.CommandFace) {\n const faceAccessor = AupCommandFace.createAccessor(face);\n super(parent, {\n findIn(parentElement: Cypress.Chainable<JQuery>): Cypress.Chainable<JQuery> {\n return faceAccessor.findIn(parentElement).closest('aup-command');\n }\n });\n }\n\n click() {\n this.getButton().click();\n }\n\n getShouldElement(): Cypress.Chainable<JQuery> {\n return this.getButton();\n }\n\n shouldBeDisabled() {\n this.getButton().should('be.disabled');\n }\n\n private getButton() {\n return this.element().find('button');\n }\n\n}\n\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
[{"__symbolic":"module","version":4,"metadata":{"AupCommand":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"../page-element","name":"PageElement","line":
|
|
1
|
+
[{"__symbolic":"module","version":4,"metadata":{"AupCommand":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"../page-element","name":"PageElement","line":4,"character":32},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"error","message":"Expression form not supported","line":6,"character":36},{"__symbolic":"select","expression":{"__symbolic":"reference","module":"./types","name":"Types","line":6,"character":77},"member":"CommandFace"}]}],"click":[{"__symbolic":"method"}],"getShouldElement":[{"__symbolic":"method"}],"shouldBeDisabled":[{"__symbolic":"method"}],"getButton":[{"__symbolic":"method"}]}}}}]
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { PageElement } from '../page-element';
|
|
2
2
|
export class AupInput extends PageElement {
|
|
3
3
|
label() {
|
|
4
|
-
return this.
|
|
4
|
+
return this.element().find('label');
|
|
5
5
|
}
|
|
6
6
|
hint() {
|
|
7
|
-
return this.
|
|
7
|
+
return this.element().find('mat-hint');
|
|
8
8
|
}
|
|
9
9
|
error() {
|
|
10
|
-
return this.
|
|
10
|
+
return this.element().find('mat-error');
|
|
11
11
|
}
|
|
12
12
|
get labelShould() {
|
|
13
13
|
return this.getShoulder(this.label());
|
|
@@ -27,23 +27,11 @@ export class AupInput extends PageElement {
|
|
|
27
27
|
errorShouldBe(text) {
|
|
28
28
|
return this.errorShould("have.text", text);
|
|
29
29
|
}
|
|
30
|
-
shouldBeFocused() {
|
|
31
|
-
this.input().should("have.focus");
|
|
32
|
-
}
|
|
33
|
-
shouldNotBeFocused() {
|
|
34
|
-
this.input().should("not.have.focus");
|
|
35
|
-
}
|
|
36
|
-
type(characters) {
|
|
37
|
-
this.input().type(characters);
|
|
38
|
-
}
|
|
39
|
-
hitEnter() {
|
|
40
|
-
this.type("{enter}");
|
|
41
|
-
}
|
|
42
30
|
}
|
|
43
31
|
(function (AupInput) {
|
|
44
32
|
class HtmlInput extends AupInput {
|
|
45
33
|
input() {
|
|
46
|
-
return this.
|
|
34
|
+
return this.element().find('input');
|
|
47
35
|
}
|
|
48
36
|
clear() {
|
|
49
37
|
this.input().clear();
|
|
@@ -64,7 +52,7 @@ export class AupInput extends PageElement {
|
|
|
64
52
|
return this.input();
|
|
65
53
|
}
|
|
66
54
|
input() {
|
|
67
|
-
return this.
|
|
55
|
+
return this.element().find('textarea');
|
|
68
56
|
}
|
|
69
57
|
clear() {
|
|
70
58
|
this.input().clear();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"aup-input.js","sourceRoot":"","sources":["../../../../../../libs/angular-ui-powerups/cypress/src/components/aup-input.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"aup-input.js","sourceRoot":"","sources":["../../../../../../libs/angular-ui-powerups/cypress/src/components/aup-input.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAE9C,MAAM,OAAgB,QAAY,SAAQ,WAAW;IAEnD,KAAK;QACH,OAAO,IAAI,CAAC,OAAO,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IACtC,CAAC;IAED,IAAI;QACF,OAAO,IAAI,CAAC,OAAO,EAAE,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;IACzC,CAAC;IAED,KAAK;QACH,OAAO,IAAI,CAAC,OAAO,EAAE,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;IAC1C,CAAC;IAED,IAAI,WAAW;QACb,OAAQ,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,KAAK,EAAE,CAAC,CAAA;IACxC,CAAC;IAED,IAAI,UAAU;QACZ,OAAQ,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;IACxC,CAAC;IAED,IAAI,WAAW;QACb,OAAQ,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,KAAK,EAAE,CAAC,CAAC;IACzC,CAAC;IAED,aAAa,CAAC,IAAY;QACxB,OAAQ,IAAI,CAAC,WAAW,CAAC,WAAW,EAAE,IAAI,CAAC,CAAC;IAC9C,CAAC;IAED,YAAY,CAAC,IAAY;QACvB,OAAQ,IAAI,CAAC,UAAU,CAAC,WAAW,EAAE,IAAI,CAAC,CAAC;IAC7C,CAAC;IAED,aAAa,CAAC,IAAY;QACxB,OAAQ,IAAI,CAAC,WAAW,CAAC,WAAW,EAAE,IAAI,CAAC,CAAC;IAC9C,CAAC;CAMF;AAED,WAAiB,QAAQ;IACvB,MAAa,SAAa,SAAQ,QAAW;QAC3C,KAAK;YACH,OAAO,IAAI,CAAC,OAAO,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACtC,CAAC;QAED,KAAK;YACH,IAAI,CAAC,KAAK,EAAE,CAAC,KAAK,EAAE,CAAC;QACvB,CAAC;QAED,QAAQ,CAAC,KAAQ;YACf,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,EAAE,CAAC;YAC3B,KAAK,CAAC,KAAK,EAAE,CAAC;YACd,KAAK,CAAC,IAAI,CAAC,GAAG,KAAK,EAAE,CAAC,CAAC;YACvB,IAAI,CAAC,KAAK,EAAE,CAAC,MAAM,CAAC,YAAY,EAAE,GAAG,KAAK,EAAE,CAAC,CAAC;QAChD,CAAC;QAED,gBAAgB;YACd,OAAO,IAAI,CAAC,KAAK,EAAE,CAAC;QACtB,CAAC;KAEF;IApBY,kBAAS,YAoBrB,CAAA;IAED,MAAa,aAAiB,SAAQ,QAAW;QAE/C,gBAAgB;YACd,OAAO,IAAI,CAAC,KAAK,EAAE,CAAC;QACtB,CAAC;QAED,KAAK;YACH,OAAO,IAAI,CAAC,OAAO,EAAE,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;QACzC,CAAC;QAED,KAAK;YACH,IAAI,CAAC,KAAK,EAAE,CAAC,KAAK,EAAE,CAAC;QACvB,CAAC;QAED,QAAQ,CAAC,KAAQ;YACf,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,EAAE,CAAC;YAC3B,KAAK,CAAC,KAAK,EAAE,CAAC;YACd,KAAK,CAAC,IAAI,CAAC,GAAG,KAAK,EAAE,CAAC,CAAC;YACvB,IAAI,CAAC,KAAK,EAAE,CAAC,MAAM,CAAC,YAAY,EAAE,KAAK,CAAC,CAAC;QAC3C,CAAC;KACF;IApBY,sBAAa,gBAoBzB,CAAA;AAEH,CAAC,EA7CgB,QAAQ,KAAR,QAAQ,QA6CxB","sourcesContent":["import { PageElement } from '../page-element';\n\nexport abstract class AupInput<T> extends PageElement {\n\n label() {\n return this.element().find('label');\n }\n\n hint() {\n return this.element().find('mat-hint');\n }\n\n error() {\n return this.element().find('mat-error');\n }\n\n get labelShould() {\n return this.getShoulder(this.label())\n }\n\n get hintShould() {\n return this.getShoulder(this.hint());\n }\n\n get errorShould() {\n return this.getShoulder(this.error());\n }\n\n labelShouldBe(text: string) {\n return this.labelShould(\"have.text\", text);\n }\n\n hintShouldBe(text: string) {\n return this.hintShould(\"have.text\", text);\n }\n\n errorShouldBe(text: string) {\n return this.errorShould(\"have.text\", text);\n }\n\n abstract clear();\n\n abstract setValue(value: T);\n\n}\n\nexport namespace AupInput {\n export class HtmlInput<T> extends AupInput<T> {\n input() {\n return this.element().find('input');\n }\n\n clear() {\n this.input().clear();\n }\n\n setValue(value: T) {\n const input = this.input();\n input.clear();\n input.type(`${value}`);\n this.input().should('have.value', `${value}`);\n }\n\n getShouldElement(): Cypress.Chainable<JQuery> {\n return this.input();\n }\n\n }\n\n export class TextAreaInput<T> extends AupInput<T> {\n\n getShouldElement(): Cypress.Chainable<JQuery> {\n return this.input();\n }\n\n input() {\n return this.element().find('textarea');\n }\n\n clear() {\n this.input().clear();\n }\n\n setValue(value: T) {\n const input = this.input();\n input.clear();\n input.type(`${value}`);\n this.input().should('have.value', value);\n }\n }\n\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
[{"__symbolic":"module","version":4,"metadata":{"AupInput":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"../page-element","name":"PageElement","line":
|
|
1
|
+
[{"__symbolic":"module","version":4,"metadata":{"AupInput":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"../page-element","name":"PageElement","line":2,"character":42},"arity":1,"members":{"label":[{"__symbolic":"method"}],"hint":[{"__symbolic":"method"}],"error":[{"__symbolic":"method"}],"labelShouldBe":[{"__symbolic":"method"}],"hintShouldBe":[{"__symbolic":"method"}],"errorShouldBe":[{"__symbolic":"method"}],"clear":[{"__symbolic":"method"}],"setValue":[{"__symbolic":"method"}]}}}}]
|