1+ /* eslint-disable @typescript-eslint/no-namespace */
2+ // ***********************************************************
3+ // This example support/component.ts is processed and
4+ // loaded automatically before your test files.
5+ //
6+ // This is a great place to put global configuration and
7+ // behavior that modifies Cypress.
8+ //
9+ // You can change the location of this file or turn off
10+ // automatically serving support files with the
11+ // 'supportFile' configuration option.
12+ //
13+ // You can read more here:
14+ // https://on.cypress.io/configuration
15+ // ***********************************************************
16+
17+ // Import commands.js using ES2015 syntax:
18+ import './commands'
19+
20+ // Alternatively you can use CommonJS syntax:
21+ // require('./commands')
22+
23+ import { mount } from 'cypress/react18'
24+
25+ // Patternfly
26+ import '@patternfly/patternfly/patternfly.css' ;
27+ // Patternfly utilities
28+ import '@patternfly/patternfly/patternfly-addons.css' ;
29+ // Global theme CSS
30+ import '@patternfly/documentation-framework/global.css' ;
31+
32+ // Augment the Cypress namespace to include type definitions for
33+ // your custom command.
34+ // Alternatively, can be defined in cypress/support/component.d.ts
35+ // with a <reference path="./component" /> at the top of your spec.
36+ declare global {
37+ namespace Cypress {
38+ interface Chainable {
39+ mount : typeof mount
40+ }
41+ }
42+ }
43+
44+ Cypress . Commands . add ( 'mount' , mount )
45+
46+ // Example use:
47+ // cy.mount(<MyComponent />)
0 commit comments