diff --git a/e2e/cypress/e2e/visual/bal-segment.visual.cy.ts b/e2e/cypress/e2e/visual/bal-segment.visual.cy.ts index 0df0bc5fe..8317c1cd1 100644 --- a/e2e/cypress/e2e/visual/bal-segment.visual.cy.ts +++ b/e2e/cypress/e2e/visual/bal-segment.visual.cy.ts @@ -1,27 +1,35 @@ describe('bal-segment', () => { beforeEach(() => cy.visit('/components/bal-segment/test/bal-segment.visual.html').waitForDesignSystem()) - it('basic component', () => { - cy.platform('desktop') - cy.getByTestId('basic').testVisual('icon-desktop') + context('mobile', () => { + beforeEach(() => cy.platform('mobile')) - cy.platform('mobile') - cy.getByTestId('basic').testVisual('icon-mobile') - }) + it('basic component', () => { + cy.getByTestId('basic').testVisual('icon-mobile') + }) - it('component horizontal', () => { - cy.platform('desktop') - cy.getByTestId('horizontal').testVisual('horizontal-desktop') + it('component horizontal', () => { + cy.getByTestId('horizontal').testVisual('horizontal-mobile') + }) - cy.platform('mobile') - cy.getByTestId('horizontal').testVisual('horizontal-mobile') + it('component vertical', () => { + cy.getByTestId('vertical').testVisual('vertical-mobile') + }) }) - it('component vertical', () => { - cy.platform('desktop') - cy.getByTestId('vertical').testVisual('vertical-desktop') + context('desktop', () => { + beforeEach(() => cy.platform('desktop')) + + it('basic component', () => { + cy.getByTestId('basic').testVisual('icon-desktop') + }) + + it('component horizontal', () => { + cy.getByTestId('horizontal').testVisual('horizontal-desktop') + }) - cy.platform('mobile') - cy.getByTestId('vertical').testVisual('vertical-mobile') + it('component vertical', () => { + cy.getByTestId('vertical').testVisual('vertical-desktop') + }) }) })