@baloise/ds-testing 0.0.5-nightly.e56f740

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.
Files changed (115) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +45 -0
  3. package/add-custom-commands.esm.d.ts +1 -0
  4. package/add-custom-commands.esm.js +4 -0
  5. package/add-override-commands.esm.d.ts +1 -0
  6. package/add-override-commands.esm.js +3 -0
  7. package/bal-input-stepper.command.esm.js +685 -0
  8. package/helpers.esm.js +359 -0
  9. package/index.esm.d.ts +1 -0
  10. package/index.esm.js +891 -0
  11. package/index.esm2.js +308 -0
  12. package/package.json +48 -0
  13. package/selectors.esm.d.ts +1 -0
  14. package/selectors.esm.js +1 -0
  15. package/src/add-custom-commands.d.ts +36 -0
  16. package/src/add-override-commands.d.ts +9 -0
  17. package/src/commands/custom/bal-accordion.command.d.ts +1 -0
  18. package/src/commands/custom/bal-accordion.types.d.ts +15 -0
  19. package/src/commands/custom/bal-datepicker.command.d.ts +1 -0
  20. package/src/commands/custom/bal-datepicker.types.d.ts +31 -0
  21. package/src/commands/custom/bal-field.command.d.ts +1 -0
  22. package/src/commands/custom/bal-field.types.d.ts +11 -0
  23. package/src/commands/custom/bal-hint.command.d.ts +1 -0
  24. package/src/commands/custom/bal-hint.types.d.ts +15 -0
  25. package/src/commands/custom/bal-input-stepper.command.d.ts +1 -0
  26. package/src/commands/custom/bal-input-stepper.types.d.ts +15 -0
  27. package/src/commands/custom/bal-modal.command.d.ts +1 -0
  28. package/src/commands/custom/bal-modal.types.d.ts +24 -0
  29. package/src/commands/custom/bal-pagination.command.d.ts +1 -0
  30. package/src/commands/custom/bal-pagination.types.d.ts +23 -0
  31. package/src/commands/custom/bal-popover.command.d.ts +1 -0
  32. package/src/commands/custom/bal-popover.types.d.ts +27 -0
  33. package/src/commands/custom/bal-popup.command.d.ts +1 -0
  34. package/src/commands/custom/bal-popup.types.d.ts +15 -0
  35. package/src/commands/custom/bal-select.command.d.ts +1 -0
  36. package/src/commands/custom/bal-select.types.d.ts +19 -0
  37. package/src/commands/custom/bal-snackbar.command.d.ts +1 -0
  38. package/src/commands/custom/bal-snackbar.types.d.ts +11 -0
  39. package/src/commands/custom/bal-steps.command.d.ts +1 -0
  40. package/src/commands/custom/bal-steps.types.d.ts +27 -0
  41. package/src/commands/custom/bal-tabs.command.d.ts +1 -0
  42. package/src/commands/custom/bal-tabs.types.d.ts +31 -0
  43. package/src/commands/custom/bal-toast.command.d.ts +1 -0
  44. package/src/commands/custom/bal-toast.types.d.ts +11 -0
  45. package/src/commands/custom/component.command.d.ts +1 -0
  46. package/src/commands/custom/component.types.d.ts +43 -0
  47. package/src/commands/custom/get.command.d.ts +1 -0
  48. package/src/commands/custom/get.types.d.ts +43 -0
  49. package/src/commands/custom/platform.command.d.ts +1 -0
  50. package/src/commands/custom/platform.types.d.ts +11 -0
  51. package/src/commands/custom/visit.command.d.ts +1 -0
  52. package/src/commands/custom/visit.types.d.ts +10 -0
  53. package/src/commands/helpers.d.ts +48 -0
  54. package/src/commands/overrides/blur.command.d.ts +1 -0
  55. package/src/commands/overrides/check.command.d.ts +1 -0
  56. package/src/commands/overrides/clear.command.d.ts +1 -0
  57. package/src/commands/overrides/click.command.d.ts +1 -0
  58. package/src/commands/overrides/focus.command.d.ts +1 -0
  59. package/src/commands/overrides/select.command.d.ts +1 -0
  60. package/src/commands/overrides/should.command.d.ts +1 -0
  61. package/src/commands/overrides/type.command.d.ts +1 -0
  62. package/src/commands/overrides/uncheck.command.d.ts +1 -0
  63. package/src/index.d.ts +25 -0
  64. package/src/legacy/accessors/accordion.accessor.d.ts +29 -0
  65. package/src/legacy/accessors/button.accessor.d.ts +23 -0
  66. package/src/legacy/accessors/checkbox.accessor.d.ts +25 -0
  67. package/src/legacy/accessors/date-picker.accessor.d.ts +24 -0
  68. package/src/legacy/accessors/drop-down.accessor.d.ts +31 -0
  69. package/src/legacy/accessors/error.accessor.d.ts +25 -0
  70. package/src/legacy/accessors/icon-accessor.d.ts +23 -0
  71. package/src/legacy/accessors/input.accessor.d.ts +30 -0
  72. package/src/legacy/accessors/link.accessor.d.ts +39 -0
  73. package/src/legacy/accessors/list.accessor.d.ts +23 -0
  74. package/src/legacy/accessors/mixins/andable.d.ts +5 -0
  75. package/src/legacy/accessors/mixins/attachable.d.ts +6 -0
  76. package/src/legacy/accessors/mixins/attributable.d.ts +7 -0
  77. package/src/legacy/accessors/mixins/blurable.d.ts +6 -0
  78. package/src/legacy/accessors/mixins/checkable.d.ts +7 -0
  79. package/src/legacy/accessors/mixins/clearable.d.ts +6 -0
  80. package/src/legacy/accessors/mixins/clickable.d.ts +7 -0
  81. package/src/legacy/accessors/mixins/containable.d.ts +5 -0
  82. package/src/legacy/accessors/mixins/disableable.d.ts +5 -0
  83. package/src/legacy/accessors/mixins/eachable.d.ts +5 -0
  84. package/src/legacy/accessors/mixins/existable.d.ts +5 -0
  85. package/src/legacy/accessors/mixins/findable.d.ts +5 -0
  86. package/src/legacy/accessors/mixins/invokable.d.ts +5 -0
  87. package/src/legacy/accessors/mixins/lengthable.d.ts +5 -0
  88. package/src/legacy/accessors/mixins/mixins.d.ts +12 -0
  89. package/src/legacy/accessors/mixins/nthSelectable.d.ts +7 -0
  90. package/src/legacy/accessors/mixins/selectable.d.ts +4 -0
  91. package/src/legacy/accessors/mixins/shouldable.d.ts +5 -0
  92. package/src/legacy/accessors/mixins/thenable.d.ts +5 -0
  93. package/src/legacy/accessors/mixins/typeable.d.ts +6 -0
  94. package/src/legacy/accessors/mixins/urlable.d.ts +6 -0
  95. package/src/legacy/accessors/mixins/visible.d.ts +5 -0
  96. package/src/legacy/accessors/mixins/waitable.d.ts +5 -0
  97. package/src/legacy/accessors/multi-select-button.accessor.d.ts +24 -0
  98. package/src/legacy/accessors/navigation.accessor.d.ts +22 -0
  99. package/src/legacy/accessors/radio.accessor.d.ts +23 -0
  100. package/src/legacy/accessors/select-button.accessor.d.ts +24 -0
  101. package/src/legacy/accessors/table.accessor.d.ts +27 -0
  102. package/src/legacy/accessors/tabs.accessor.d.ts +26 -0
  103. package/src/legacy/accessors/text.accessor.d.ts +23 -0
  104. package/src/legacy/accessors/tile.accessor.d.ts +27 -0
  105. package/src/legacy/accessors/toast.accessor.d.ts +24 -0
  106. package/src/legacy/accessors/tooltip.accessor.d.ts +23 -0
  107. package/src/legacy/accessors/typeahead.accessor.d.ts +26 -0
  108. package/src/legacy/index.d.ts +44 -0
  109. package/src/selectors/index.d.ts +342 -0
  110. package/src/selectors/selectors.util.d.ts +4 -0
  111. package/src/selectors.d.ts +1 -0
  112. package/src/viewports.d.ts +7 -0
  113. package/type.command.esm.js +471 -0
  114. package/viewports.esm.d.ts +1 -0
  115. package/viewports.esm.js +46 -0
@@ -0,0 +1,27 @@
1
+ /// <reference types="cypress" />
2
+ /// <reference types="cypress" />
3
+ /// <reference types="cypress" />
4
+ declare namespace Cypress {
5
+ interface Chainable {
6
+ /**
7
+ * Returns the tab items.
8
+ */
9
+ balStepsFindItems(options?: Partial<Loggable>): Chainable<JQuery>;
10
+ /**
11
+ * Returns the label of the tab item.
12
+ */
13
+ balStepsFindLabel(options?: Partial<Loggable>): Chainable<JQuery>;
14
+ /**
15
+ * Assert that the tab has the given item.
16
+ */
17
+ balStepsShouldHaveItems(labels: string[], dataType?: 'label' | 'value', options?: Partial<Loggable>): Chainable<JQuery>;
18
+ /**
19
+ * Assert that the tab item has the given state.
20
+ */
21
+ balStepsItemShouldHaveState(state: 'done' | 'failed' | 'active' | 'disabled', options?: Partial<Loggable>): Chainable<JQuery>;
22
+ /**
23
+ * Assert that the tab item has not the given state.
24
+ */
25
+ balStepsItemShouldNotHaveState(state: 'done' | 'failed' | 'active' | 'disabled', options?: Partial<Loggable>): Chainable<JQuery>;
26
+ }
27
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,31 @@
1
+ /// <reference types="cypress" />
2
+ /// <reference types="cypress" />
3
+ /// <reference types="cypress" />
4
+ declare namespace Cypress {
5
+ interface Chainable {
6
+ /**
7
+ * Returns the action button element.
8
+ */
9
+ balTabsFindActionButton(options?: Partial<Loggable>): Chainable<JQuery>;
10
+ /**
11
+ * Returns the tab items.
12
+ */
13
+ balTabsFindItems(options?: Partial<Loggable>): Chainable<JQuery>;
14
+ /**
15
+ * Returns the label of the tab item.
16
+ */
17
+ balTabsFindLabel(options?: Partial<Loggable>): Chainable<JQuery>;
18
+ /**
19
+ * Assert that the tab has the given item.
20
+ */
21
+ balTabsShouldHaveItems(labels: string[], dataType?: 'label' | 'value', options?: Partial<Loggable>): Chainable<JQuery>;
22
+ /**
23
+ * Assert that the tab item has the given state.
24
+ */
25
+ balTabItemShouldHaveState(state: 'done' | 'failed' | 'active' | 'disabled', options?: Partial<Loggable>): Chainable<JQuery>;
26
+ /**
27
+ * Assert that the tab item is active or not.
28
+ */
29
+ balTabItemShouldBeActive(active?: boolean, options?: Partial<Loggable>): Chainable<JQuery>;
30
+ }
31
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,11 @@
1
+ /// <reference types="cypress" />
2
+ /// <reference types="cypress" />
3
+ /// <reference types="cypress" />
4
+ declare namespace Cypress {
5
+ interface Chainable {
6
+ /**
7
+ * Returns the visible toasts.
8
+ */
9
+ balToastFind(options?: Partial<Loggable>): Chainable<JQuery>;
10
+ }
11
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,43 @@
1
+ /// <reference types="cypress" />
2
+ /// <reference types="cypress" />
3
+ /// <reference types="cypress" />
4
+ declare namespace Cypress {
5
+ interface Chainable {
6
+ /**
7
+ * Disabled all animations for the Design System components.
8
+ */
9
+ disableAnimation(): Chainable<JQuery>;
10
+ /**
11
+ * Disabled all logs for the Design System components.
12
+ */
13
+ disableLogger(): Chainable<JQuery>;
14
+ /**
15
+ * Waits until the component is fully loaded.
16
+ */
17
+ waitForComponents(options?: Partial<Loggable & Timeoutable>): Chainable<JQuery>;
18
+ /**
19
+ * Gets component and waits until it is ready
20
+ */
21
+ getComponent(selector: string, options?: Partial<Loggable>): Chainable<JQuery>;
22
+ /**
23
+ * Wraps component and waits until it is ready.
24
+ */
25
+ wrapComponent(element: any, options?: Partial<Loggable & Timeoutable>): Chainable<JQuery>;
26
+ /**
27
+ * Waits until the Design System is fully loaded and rendered
28
+ */
29
+ waitForDesignSystem(): Chainable<JQuery>;
30
+ /**
31
+ * Waits until the browser goes into idle mode
32
+ */
33
+ waitAfterIdleCallback(): Chainable<JQuery>;
34
+ /**
35
+ * Waits until the browser finished rendering
36
+ */
37
+ waitAfterFramePaint(): Chainable<JQuery>;
38
+ /**
39
+ * Waits until the browser finished rendering
40
+ */
41
+ waitForBrowser(): Chainable<JQuery>;
42
+ }
43
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,43 @@
1
+ /// <reference types="cypress" />
2
+ /// <reference types="cypress" />
3
+ /// <reference types="cypress" />
4
+ declare namespace Cypress {
5
+ interface GetByRoleOptions {
6
+ name?: string;
7
+ hidden?: boolean;
8
+ }
9
+ interface Chainable {
10
+ /**
11
+ * Gets the element by data-testid or data-test.
12
+ */
13
+ getByTestId(testId: string, options?: Partial<Loggable & Timeoutable & Withinable & Shadow>): Chainable<JQuery>;
14
+ /**
15
+ * Gets the control elements to the given subject
16
+ */
17
+ getControl(labelText: string, options?: Partial<Loggable & Timeoutable & Withinable & Shadow>): Chainable<void>;
18
+ /**
19
+ * Gets the elements who describes the subject
20
+ */
21
+ getDescribingElement(options?: Partial<Loggable & Timeoutable & Withinable & Shadow>): Chainable<void>;
22
+ /**
23
+ * Asserts if the form element is invalid
24
+ */
25
+ shouldBeInvalid(options?: Partial<Loggable & Timeoutable & Withinable & Shadow>): Chainable<void>;
26
+ /**
27
+ * Asserts if the form element is valid
28
+ */
29
+ shouldBeValid(options?: Partial<Loggable & Timeoutable & Withinable & Shadow>): Chainable<void>;
30
+ /**
31
+ * Gets a element by the label
32
+ */
33
+ getByLabelText(labelText: string, options?: Partial<Loggable & Timeoutable & Withinable & Shadow>): Chainable<void>;
34
+ /**
35
+ * Gets a element by the placeholder
36
+ */
37
+ getByPlaceholder(placeholder: string, options?: Partial<Loggable & Timeoutable & Withinable & Shadow>): Chainable<JQuery>;
38
+ /**
39
+ * Gets a element by the role
40
+ */
41
+ getByRole(role: 'button' | 'label', options: Partial<GetByRoleOptions & Loggable & Timeoutable & Withinable & Shadow>): Chainable<JQuery>;
42
+ }
43
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,11 @@
1
+ import { Platforms } from '../helpers';
2
+ declare global {
3
+ namespace Cypress {
4
+ interface Chainable {
5
+ /**
6
+ * Custom command to set the viewport / platform.
7
+ */
8
+ platform(platform: Platforms): Chainable<Element>;
9
+ }
10
+ }
11
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,10 @@
1
+ /// <reference types="cypress" />
2
+ declare namespace Cypress {
3
+ interface Chainable {
4
+ /**
5
+ * Open an application with the Design System and waits
6
+ * until the Design System has fully loaded.
7
+ */
8
+ visitBalApp(url: string, options?: Partial<VisitOptions>): Chainable<AUTWindow>;
9
+ }
10
+ }
@@ -0,0 +1,48 @@
1
+ /// <reference types="cypress" />
2
+ /// <reference types="cypress" />
3
+ export declare type Platforms = 'mobile' | 'tablet' | 'touch' | 'desktop' | 'highDefinition' | 'widescreen' | 'fullhd';
4
+ export declare const deepReady: (el: any | undefined, full?: boolean) => Promise<void>;
5
+ export declare const rIC: (callback: () => void, timeout?: number) => void;
6
+ export declare const waitAfterFramePaint: () => Promise<unknown>;
7
+ export declare const waitAfterIdleCallback: (timeout?: number) => Promise<unknown>;
8
+ export declare const raf: (h: any) => any;
9
+ export declare const runHighPrioritizedTask: (callback: (value: unknown) => void) => void;
10
+ /**
11
+ * Helper fn to identify the element/component
12
+ */
13
+ export declare type isElementType = (el: Cypress.Chainable<JQuery>) => boolean;
14
+ export declare const isElement: (el: Cypress.Chainable<JQuery>, name: string) => boolean;
15
+ export declare const hasClass: (el: Cypress.Chainable<JQuery>, name: string) => boolean;
16
+ export declare const hasTestId: (el: Cypress.Chainable<JQuery>, testId: string) => boolean;
17
+ export declare const isLabel: isElementType;
18
+ export declare const isAccordion: isElementType;
19
+ export declare const isButton: isElementType;
20
+ export declare const isCheckbox: isElementType;
21
+ export declare const isDatepicker: isElementType;
22
+ export declare const isNumberInput: isElementType;
23
+ export declare const isModal: isElementType;
24
+ export declare const isRadioGroup: isElementType;
25
+ export declare const isRadio: isElementType;
26
+ export declare const isSelect: isElementType;
27
+ export declare const isTag: isElementType;
28
+ export declare const isTabs: isElementType;
29
+ export declare const isSteps: isElementType;
30
+ export declare const isSlider: isElementType;
31
+ export declare const isHint: isElementType;
32
+ export declare const isTextarea: isElementType;
33
+ export declare const isCardTitle: isElementType;
34
+ export declare const isHeading: isElementType;
35
+ export declare const isText: isElementType;
36
+ export declare const isInputStepper: isElementType;
37
+ export declare const isInput: isElementType;
38
+ export declare const isInputDate: isElementType;
39
+ /**
40
+ * Executes a command on a child element and wraps back to the main element/component
41
+ */
42
+ export declare const wrapOptions: (options: any) => any;
43
+ export declare const wrapCommand: (displayName: string, element: Cypress.Chainable<JQuery>, message: any, fn: ($el: any) => Cypress.Chainable<JQuery> | void) => (selector: string) => Cypress.Chainable<JQuery<HTMLElement>>;
44
+ export declare const shouldLog: (options?: Partial<Cypress.Loggable>) => boolean;
45
+ export declare const log: (displayName: string, message: any, $el: any, options?: Partial<Cypress.Loggable>) => void;
46
+ export declare const areComponentsReady: ($el: any) => Promise<void[]>;
47
+ export declare const testOnPlatforms: (platforms: Platforms[], fn: (platform: Platforms) => Promise<void> | void) => void;
48
+ export declare function checkAriaLabel(element: HTMLElement, label: string | undefined | null): boolean;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
package/src/index.d.ts ADDED
@@ -0,0 +1,25 @@
1
+ /**
2
+ * Selector utilities
3
+ */
4
+ export * from './selectors';
5
+ /**
6
+ * Viewports sizes
7
+ */
8
+ export * from './viewports';
9
+ /**
10
+ * Helpers
11
+ */
12
+ export type { Platforms } from './commands/helpers';
13
+ export { testOnPlatforms } from './commands/helpers';
14
+ /**
15
+ * Legacy Commands
16
+ */
17
+ export * from './legacy';
18
+ /**
19
+ * Custom Commands
20
+ */
21
+ import './add-custom-commands';
22
+ /**
23
+ * Override Commands
24
+ */
25
+ import './add-override-commands';
@@ -0,0 +1,29 @@
1
+ /// <reference types="cypress" />
2
+ import { Andable } from './mixins/andable';
3
+ import { Attributable } from './mixins/attributable';
4
+ import { Blurable } from './mixins/blurable';
5
+ import { Clickable } from './mixins/clickable';
6
+ import { Containable } from './mixins/containable';
7
+ import { Eachable } from './mixins/eachable';
8
+ import { Existable } from './mixins/existable';
9
+ import { Findable } from './mixins/findable';
10
+ import { Invokable } from './mixins/invokable';
11
+ import { Lengthable } from './mixins/lengthable';
12
+ import { Accessor, Mixin } from './mixins/mixins';
13
+ import { NthSelectable } from './mixins/nthSelectable';
14
+ import { Shouldable } from './mixins/shouldable';
15
+ import { Thenable } from './mixins/thenable';
16
+ import { Urlable } from './mixins/urlable';
17
+ import { Visible } from './mixins/visible';
18
+ import { Waitable } from './mixins/waitable';
19
+ interface AccordionTileAccessorType extends Andable<AccordionTileAccessorType>, Blurable<AccordionTileAccessorType>, Clickable<AccordionTileAccessorType>, Existable<AccordionTileAccessorType>, Visible<AccordionTileAccessorType>, Containable<AccordionTileAccessorType>, Shouldable<AccordionTileAccessorType>, NthSelectable<AccordionTileAccessorType>, Attributable<AccordionTileAccessorType>, Urlable<AccordionTileAccessorType>, Findable<AccordionTileAccessorType>, Waitable<AccordionTileAccessorType>, Invokable<AccordionTileAccessorType>, Thenable<AccordionTileAccessorType>, Lengthable<AccordionTileAccessorType>, Eachable<AccordionTileAccessorType> {
20
+ assertBodyExists(): AccordionTileAccessorType;
21
+ assertBodyNotExists(): AccordionTileAccessorType;
22
+ clickBody(options?: Partial<Cypress.ClickOptions>): AccordionTileAccessorType;
23
+ }
24
+ export declare const AccordionTileClickableMixin: Mixin;
25
+ export declare const AccordionClickableMixin: Mixin;
26
+ export declare const AccordionContainableMixin: Mixin;
27
+ export declare const AccordionAssertableMixin: Mixin;
28
+ export declare const AccordionAccessor: Accessor<AccordionTileAccessorType>;
29
+ export {};
@@ -0,0 +1,23 @@
1
+ import { Andable } from './mixins/andable';
2
+ import { Attachable } from './mixins/attachable';
3
+ import { Attributable } from './mixins/attributable';
4
+ import { Blurable } from './mixins/blurable';
5
+ import { Clickable } from './mixins/clickable';
6
+ import { Containable } from './mixins/containable';
7
+ import { Disableable } from './mixins/disableable';
8
+ import { Eachable } from './mixins/eachable';
9
+ import { Existable } from './mixins/existable';
10
+ import { Findable } from './mixins/findable';
11
+ import { Invokable } from './mixins/invokable';
12
+ import { Lengthable } from './mixins/lengthable';
13
+ import { Accessor } from './mixins/mixins';
14
+ import { NthSelectable } from './mixins/nthSelectable';
15
+ import { Shouldable } from './mixins/shouldable';
16
+ import { Thenable } from './mixins/thenable';
17
+ import { Urlable } from './mixins/urlable';
18
+ import { Visible } from './mixins/visible';
19
+ import { Waitable } from './mixins/waitable';
20
+ interface ButtonAccessorType extends Andable<ButtonAccessorType>, Blurable<ButtonAccessorType>, Clickable<ButtonAccessorType>, Existable<ButtonAccessorType>, Shouldable<ButtonAccessorType>, Containable<ButtonAccessorType>, Disableable<ButtonAccessorType>, Visible<ButtonAccessorType>, NthSelectable<ButtonAccessorType>, Attributable<ButtonAccessorType>, Urlable<ButtonAccessorType>, Findable<ButtonAccessorType>, Waitable<ButtonAccessorType>, Invokable<ButtonAccessorType>, Thenable<ButtonAccessorType>, Lengthable<ButtonAccessorType>, Eachable<ButtonAccessorType>, Attachable<ButtonAccessorType> {
21
+ }
22
+ export declare const ButtonAccessor: Accessor<ButtonAccessorType>;
23
+ export {};
@@ -0,0 +1,25 @@
1
+ import { Andable } from './mixins/andable';
2
+ import { Attributable } from './mixins/attributable';
3
+ import { Blurable } from './mixins/blurable';
4
+ import { Checkable } from './mixins/checkable';
5
+ import { Clickable } from './mixins/clickable';
6
+ import { Containable } from './mixins/containable';
7
+ import { Disableable } from './mixins/disableable';
8
+ import { Eachable } from './mixins/eachable';
9
+ import { Existable } from './mixins/existable';
10
+ import { Findable } from './mixins/findable';
11
+ import { Invokable } from './mixins/invokable';
12
+ import { Lengthable } from './mixins/lengthable';
13
+ import { Accessor, Mixin } from './mixins/mixins';
14
+ import { NthSelectable } from './mixins/nthSelectable';
15
+ import { Shouldable } from './mixins/shouldable';
16
+ import { Thenable } from './mixins/thenable';
17
+ import { Urlable } from './mixins/urlable';
18
+ import { Visible } from './mixins/visible';
19
+ import { Waitable } from './mixins/waitable';
20
+ interface CheckboxAccessorType extends Andable<CheckboxAccessorType>, Blurable<CheckboxAccessorType>, Clickable<CheckboxAccessorType>, Disableable<CheckboxAccessorType>, Checkable<CheckboxAccessorType>, Containable<CheckboxAccessorType>, Existable<CheckboxAccessorType>, Visible<CheckboxAccessorType>, NthSelectable<CheckboxAccessorType>, Shouldable<CheckboxAccessorType>, Attributable<CheckboxAccessorType>, Urlable<CheckboxAccessorType>, Findable<CheckboxAccessorType>, Waitable<CheckboxAccessorType>, Invokable<CheckboxAccessorType>, Thenable<CheckboxAccessorType>, Lengthable<CheckboxAccessorType>, Eachable<CheckboxAccessorType> {
21
+ }
22
+ export declare const CheckboxClickableMixin: Mixin;
23
+ export declare const CheckboxContainableMixin: Mixin;
24
+ export declare const CheckboxAccessor: Accessor<CheckboxAccessorType>;
25
+ export {};
@@ -0,0 +1,24 @@
1
+ import { Accessor, Mixin } from './mixins/mixins';
2
+ export interface DatePickerAccessorType {
3
+ write(date: string): DatePickerAccessorType;
4
+ pick(date: Date): DatePickerAccessorType;
5
+ open(): DatePickerAccessorType;
6
+ shouldHaveValue(date: Date): DatePickerAccessorType;
7
+ errorCheck(name: string, error: string): void;
8
+ noErrorCheck(name: string): void;
9
+ assertDateInRange(date: Date, shouldBeInRange?: boolean): DatePickerAccessorType;
10
+ }
11
+ export declare const DatePickerWriteMixin: Mixin;
12
+ export declare const DatePickerPickableMixin: Mixin;
13
+ export declare const DatePickerOpenableMixin: Mixin;
14
+ export declare const DatePickerShouldHaveValueAssertableMixin: Mixin;
15
+ /**
16
+ * TODO: need to rework
17
+ */
18
+ export declare const DatePickerErrorAssertableMixin: Mixin;
19
+ /**
20
+ * TODO: need to rework
21
+ */
22
+ export declare const DatePickerNoErrorAssertableMixin: Mixin;
23
+ export declare const DatePickerMinMaxRangeAssertableMixin: Mixin;
24
+ export declare const DatePickerAccessor: Accessor<DatePickerAccessorType>;
@@ -0,0 +1,31 @@
1
+ import { Andable } from './mixins/andable';
2
+ import { Attributable } from './mixins/attributable';
3
+ import { Blurable } from './mixins/blurable';
4
+ import { Clickable } from './mixins/clickable';
5
+ import { Containable } from './mixins/containable';
6
+ import { Disableable } from './mixins/disableable';
7
+ import { Eachable } from './mixins/eachable';
8
+ import { Existable } from './mixins/existable';
9
+ import { Findable } from './mixins/findable';
10
+ import { Invokable } from './mixins/invokable';
11
+ import { Lengthable } from './mixins/lengthable';
12
+ import { Accessor, Mixin } from './mixins/mixins';
13
+ import { NthSelectable } from './mixins/nthSelectable';
14
+ import { Selectable } from './mixins/selectable';
15
+ import { Shouldable } from './mixins/shouldable';
16
+ import { Thenable } from './mixins/thenable';
17
+ import { Urlable } from './mixins/urlable';
18
+ import { Visible } from './mixins/visible';
19
+ import { Waitable } from './mixins/waitable';
20
+ interface DropDownAccessorType extends Andable<DropDownAccessorType>, Blurable<DropDownAccessorType>, Clickable<DropDownAccessorType>, Selectable<DropDownAccessorType>, Disableable<DropDownAccessorType>, Containable<DropDownAccessorType>, Shouldable<DropDownAccessorType>, Visible<DropDownAccessorType>, NthSelectable<DropDownAccessorType>, Attributable<DropDownAccessorType>, Urlable<DropDownAccessorType>, Findable<DropDownAccessorType>, Waitable<DropDownAccessorType>, Existable<DropDownAccessorType>, Invokable<DropDownAccessorType>, Thenable<DropDownAccessorType>, Lengthable<DropDownAccessorType>, Eachable<DropDownAccessorType> {
21
+ assertOptions(...options: string[]): DropDownAccessorType;
22
+ }
23
+ export declare const DropDownClickableMixin: Mixin;
24
+ export declare const DropDownSelectableMixin: Mixin;
25
+ export declare function SiblingDropDownSelectableMixin(): Mixin;
26
+ export declare const DropDownAssertableOptionsMixin: Mixin;
27
+ export declare function SiblingDropDownAssertableOptionsMixin(): Mixin;
28
+ export declare const DropDownContainableMixin: Mixin;
29
+ export declare function SiblingDropDownContainableMixin(): Mixin;
30
+ export declare const DropDownAccessor: Accessor<DropDownAccessorType>;
31
+ export {};
@@ -0,0 +1,25 @@
1
+ import { Andable } from './mixins/andable';
2
+ import { Attributable } from './mixins/attributable';
3
+ import { Clickable } from './mixins/clickable';
4
+ import { Eachable } from './mixins/eachable';
5
+ import { Existable } from './mixins/existable';
6
+ import { Findable } from './mixins/findable';
7
+ import { Invokable } from './mixins/invokable';
8
+ import { Lengthable } from './mixins/lengthable';
9
+ import { Accessor, Mixin } from './mixins/mixins';
10
+ import { NthSelectable } from './mixins/nthSelectable';
11
+ import { Shouldable } from './mixins/shouldable';
12
+ import { Thenable } from './mixins/thenable';
13
+ import { Urlable } from './mixins/urlable';
14
+ import { Visible } from './mixins/visible';
15
+ import { Waitable } from './mixins/waitable';
16
+ interface ErrorAccessorType extends Andable<ErrorAccessorType>, Clickable<ErrorAccessorType>, Existable<ErrorAccessorType>, Shouldable<ErrorAccessorType>, Visible<ErrorAccessorType>, NthSelectable<ErrorAccessorType>, Attributable<ErrorAccessorType>, Urlable<ErrorAccessorType>, Findable<ErrorAccessorType>, Waitable<ErrorAccessorType>, Invokable<ErrorAccessorType>, Thenable<ErrorAccessorType>, Lengthable<ErrorAccessorType>, Eachable<ErrorAccessorType> {
17
+ assertError(error: string): ErrorAccessorType;
18
+ assertNoError(): ErrorAccessorType;
19
+ }
20
+ /**
21
+ * TODO: adjust to the DS
22
+ */
23
+ export declare const ErrorAssertableMixin: Mixin;
24
+ export declare const ErrorAccessor: Accessor<ErrorAccessorType>;
25
+ export {};
@@ -0,0 +1,23 @@
1
+ import { Andable } from './mixins/andable';
2
+ import { Attributable } from './mixins/attributable';
3
+ import { Blurable } from './mixins/blurable';
4
+ import { Clickable } from './mixins/clickable';
5
+ import { Containable } from './mixins/containable';
6
+ import { Eachable } from './mixins/eachable';
7
+ import { Existable } from './mixins/existable';
8
+ import { Findable } from './mixins/findable';
9
+ import { Invokable } from './mixins/invokable';
10
+ import { Lengthable } from './mixins/lengthable';
11
+ import { Accessor, Mixin } from './mixins/mixins';
12
+ import { NthSelectable } from './mixins/nthSelectable';
13
+ import { Shouldable } from './mixins/shouldable';
14
+ import { Thenable } from './mixins/thenable';
15
+ import { Urlable } from './mixins/urlable';
16
+ import { Visible } from './mixins/visible';
17
+ import { Waitable } from './mixins/waitable';
18
+ interface IconAccessorType extends Andable<IconAccessorType>, Blurable<IconAccessorType>, Existable<IconAccessorType>, Containable<IconAccessorType>, Clickable<IconAccessorType>, Shouldable<IconAccessorType>, Visible<IconAccessorType>, NthSelectable<IconAccessorType>, Attributable<IconAccessorType>, Urlable<IconAccessorType>, Findable<IconAccessorType>, Waitable<IconAccessorType>, Invokable<IconAccessorType>, Thenable<IconAccessorType>, Lengthable<IconAccessorType>, Eachable<IconAccessorType> {
19
+ assertIcon(id: string): IconAccessorType;
20
+ }
21
+ export declare const LibIconAssertableMixin: Mixin;
22
+ export declare const IconAccessor: Accessor<IconAccessorType>;
23
+ export {};
@@ -0,0 +1,30 @@
1
+ import { Andable } from './mixins/andable';
2
+ import { Attachable } from './mixins/attachable';
3
+ import { Attributable } from './mixins/attributable';
4
+ import { Blurable } from './mixins/blurable';
5
+ import { Clearable } from './mixins/clearable';
6
+ import { Clickable } from './mixins/clickable';
7
+ import { Containable } from './mixins/containable';
8
+ import { Disableable } from './mixins/disableable';
9
+ import { Eachable } from './mixins/eachable';
10
+ import { Existable } from './mixins/existable';
11
+ import { Findable } from './mixins/findable';
12
+ import { Invokable } from './mixins/invokable';
13
+ import { Lengthable } from './mixins/lengthable';
14
+ import { Accessor, Mixin } from './mixins/mixins';
15
+ import { NthSelectable } from './mixins/nthSelectable';
16
+ import { Shouldable } from './mixins/shouldable';
17
+ import { Thenable } from './mixins/thenable';
18
+ import { Typeable } from './mixins/typeable';
19
+ import { Urlable } from './mixins/urlable';
20
+ import { Visible } from './mixins/visible';
21
+ import { Waitable } from './mixins/waitable';
22
+ interface InputAccessorType extends Andable<InputAccessorType>, Clickable<InputAccessorType>, Typeable<InputAccessorType>, Blurable<InputAccessorType>, Clearable<InputAccessorType>, Visible<InputAccessorType>, Containable<InputAccessorType>, Existable<InputAccessorType>, Shouldable<InputAccessorType>, Disableable<InputAccessorType>, NthSelectable<InputAccessorType>, Attributable<InputAccessorType>, Urlable<InputAccessorType>, Findable<InputAccessorType>, Waitable<InputAccessorType>, Invokable<InputAccessorType>, Thenable<InputAccessorType>, Lengthable<InputAccessorType>, Eachable<InputAccessorType>, Attachable<InputAccessorType> {
23
+ assertValue(value: any): InputAccessorType;
24
+ contains(content: string | number | RegExp): InputAccessorType;
25
+ assertError(error: string): InputAccessorType;
26
+ assertNoError(): InputAccessorType;
27
+ }
28
+ export declare const InputValueAssertableMixin: Mixin;
29
+ export declare const InputAccessor: Accessor<InputAccessorType>;
30
+ export {};
@@ -0,0 +1,39 @@
1
+ import { Andable } from './mixins/andable';
2
+ import { Attachable } from './mixins/attachable';
3
+ import { Attributable } from './mixins/attributable';
4
+ import { Blurable } from './mixins/blurable';
5
+ import { Clickable } from './mixins/clickable';
6
+ import { Containable } from './mixins/containable';
7
+ import { Disableable } from './mixins/disableable';
8
+ import { Eachable } from './mixins/eachable';
9
+ import { Existable } from './mixins/existable';
10
+ import { Findable } from './mixins/findable';
11
+ import { Invokable } from './mixins/invokable';
12
+ import { Lengthable } from './mixins/lengthable';
13
+ import { Accessor, Mixin } from './mixins/mixins';
14
+ import { NthSelectable } from './mixins/nthSelectable';
15
+ import { Shouldable } from './mixins/shouldable';
16
+ import { Thenable } from './mixins/thenable';
17
+ import { Urlable } from './mixins/urlable';
18
+ import { Visible } from './mixins/visible';
19
+ import { Waitable } from './mixins/waitable';
20
+ export declare enum Target {
21
+ newTab = "_blank",
22
+ sameTab = "_self",
23
+ parent = "_parent",
24
+ top = "_top"
25
+ }
26
+ interface LinkAccessorType extends Andable<LinkAccessorType>, Blurable<LinkAccessorType>, Clickable<LinkAccessorType>, Existable<LinkAccessorType>, Shouldable<LinkAccessorType>, Containable<LinkAccessorType>, Disableable<LinkAccessorType>, Visible<LinkAccessorType>, NthSelectable<LinkAccessorType>, Attributable<LinkAccessorType>, Urlable<LinkAccessorType>, Findable<LinkAccessorType>, Waitable<LinkAccessorType>, Invokable<LinkAccessorType>, Thenable<LinkAccessorType>, Lengthable<LinkAccessorType>, Eachable<LinkAccessorType>, Attachable<LinkAccessorType> {
27
+ clickLink(): LinkAccessorType;
28
+ assertLinkOpeningTarget(target: Target): LinkAccessorType;
29
+ assertLinkWithoutTarget(): LinkAccessorType;
30
+ assertHrefContains(href: string): LinkAccessorType;
31
+ assertHrefEquals(href: string): LinkAccessorType;
32
+ }
33
+ export declare const LinkClickableMixin: Mixin;
34
+ export declare const LinkWithTargetAttribute: Mixin;
35
+ export declare const LinkWithoutTargetAttribute: Mixin;
36
+ export declare const LinkHrefContainsAssertableMixin: Mixin;
37
+ export declare const LinkHrefEqualsAssertableMixin: Mixin;
38
+ export declare const LinkAccessor: Accessor<LinkAccessorType>;
39
+ export {};
@@ -0,0 +1,23 @@
1
+ import { Andable } from './mixins/andable';
2
+ import { Attributable } from './mixins/attributable';
3
+ import { Clickable } from './mixins/clickable';
4
+ import { Containable } from './mixins/containable';
5
+ import { Disableable } from './mixins/disableable';
6
+ import { Existable } from './mixins/existable';
7
+ import { Findable } from './mixins/findable';
8
+ import { Invokable } from './mixins/invokable';
9
+ import { Lengthable } from './mixins/lengthable';
10
+ import { Accessor, Mixin } from './mixins/mixins';
11
+ import { NthSelectable } from './mixins/nthSelectable';
12
+ import { Selectable } from './mixins/selectable';
13
+ import { Shouldable } from './mixins/shouldable';
14
+ import { Thenable } from './mixins/thenable';
15
+ import { Urlable } from './mixins/urlable';
16
+ import { Visible } from './mixins/visible';
17
+ import { Waitable } from './mixins/waitable';
18
+ interface ListAccessorType extends Andable<ListAccessorType>, Selectable<ListAccessorType>, Containable<ListAccessorType>, Existable<ListAccessorType>, Clickable<ListAccessorType>, Disableable<ListAccessorType>, Shouldable<ListAccessorType>, Visible<ListAccessorType>, NthSelectable<ListAccessorType>, Attributable<ListAccessorType>, Urlable<ListAccessorType>, Findable<ListAccessorType>, Waitable<ListAccessorType>, Invokable<ListAccessorType>, Thenable<ListAccessorType>, Lengthable<ListAccessorType>, Lengthable<ListAccessorType> {
19
+ }
20
+ export declare const ListSelectableMixin: Mixin;
21
+ export declare const ListAssertableMixin: Mixin;
22
+ export declare const ListAccessor: Accessor<ListAccessorType>;
23
+ export {};
@@ -0,0 +1,5 @@
1
+ import { Mixin } from './mixins';
2
+ export interface Andable<T> {
3
+ and(chainers: string, method?: string, value?: string): T;
4
+ }
5
+ export declare const AndableMixin: Mixin;
@@ -0,0 +1,6 @@
1
+ import 'cypress-file-upload';
2
+ import { Mixin } from './mixins';
3
+ export interface Attachable<T> {
4
+ attachFile(fileLocation: string, attachmentMethod?: 'input' | 'drag-n-drop'): T;
5
+ }
6
+ export declare const AttachableMixin: Mixin;
@@ -0,0 +1,7 @@
1
+ import { Mixin } from './mixins';
2
+ export interface Attributable<T> {
3
+ assertAttributeEquals(attribute: string, value: string): T;
4
+ assertAttributeInclude(attribute: string, value: string): T;
5
+ assertDoesNotHaveAttribute(attribute: string): T;
6
+ }
7
+ export declare const AttributableMixin: Mixin;
@@ -0,0 +1,6 @@
1
+ /// <reference types="cypress" />
2
+ import { Mixin } from './mixins';
3
+ export interface Blurable<T> {
4
+ blur(options?: Partial<Cypress.BlurOptions>): T;
5
+ }
6
+ export declare const BlurableMixin: Mixin;