Skip to content

Commit

Permalink
moving verify icons custom command
Browse files Browse the repository at this point in the history
  • Loading branch information
mschile committed Jan 6, 2025
1 parent 56a578a commit a7bf68d
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 3 deletions.
1 change: 0 additions & 1 deletion packages/app/cypress/component/support/ctSupport.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import { AutIframe } from '../../../src/runner/aut-iframe'
import { EventManager } from '../../../src/runner/event-manager'
import '../../e2e/support/browserIconCommands'
import type { Socket } from '@packages/socket/lib/browser'

export const StubWebsocket = new Proxy<Socket>(Object.create(null), {
Expand Down
1 change: 0 additions & 1 deletion packages/app/cypress/e2e/support/e2eSupport.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import '@packages/frontend-shared/cypress/support/e2e'
import './browserIconCommands'
import 'cypress-real-events/support'
import './execute-spec'

Expand Down
1 change: 1 addition & 0 deletions packages/frontend-shared/cypress/support/component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import { registerMountFn, addVueCommand } from './common'
import '../../src/styles/shared.scss'
import 'tailwindcss/tailwind.css'
import 'cypress-real-events/support'
import './browserIconCommands'
import { installCustomPercyCommand } from './customPercyCommand'
import { addNetworkCommands } from './onlineNetwork'
import { GQLStubRegistry } from './mock-graphql/stubgql-Registry'
Expand Down
1 change: 1 addition & 0 deletions packages/frontend-shared/cypress/support/e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import i18n from '../../src/locales/en-US.json'
import { addNetworkCommands } from './onlineNetwork'
import { logInternal } from './utils'
import { tabUntil } from './tab-until'
import './browserIconCommands'

configure({ testIdAttribute: 'data-cy' })

Expand Down
3 changes: 2 additions & 1 deletion packages/launchpad/src/setup/OpenBrowserList.cy.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { OpenBrowserListFragmentDoc } from '../generated/graphql-test'
import OpenBrowserList from './OpenBrowserList.vue'
import { longBrowsersList } from '@packages/frontend-shared/cypress/support/mock-graphql/longBrowsersList'
import { defaultMessages } from '@cy/i18n'
import { cyGeneralGlobeX16 } from '@cypress-design/icon-registry'

// Testing Note: because state for this component is maintained on the server and updated via gql mutations,
// this component test can't do interactions that change the chosen browser at the moment. Interactions and states
Expand Down Expand Up @@ -31,7 +32,7 @@ describe('<OpenBrowserList />', () => {

// Renders a default logo if we don't provide one
cy.get('[data-cy-browser="fake"]').should('have.attr', 'aria-disabled', 'true')
cy.get('[data-cy-browser="fake"] img').should('have.attr', 'src').should('include', 'generic-browser')
cy.get('[data-cy-browser="fake"] svg').eq(0).children().verifyBrowserIconSvg(cyGeneralGlobeX16.data)

cy.percySnapshot()
})
Expand Down

0 comments on commit a7bf68d

Please sign in to comment.