Browse Source

fix: recommended apps button test

Regression of https://github.com/nextcloud/server/pull/52703 where the
`>` was added by accident and thus the button has a wrong label
including the rest of the button HTML.

Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
pull/53047/head
Ferdinand Thiessen 6 months ago
parent
commit
d535c377cf
  1. 9
      core/src/components/setup/RecommendedApps.vue
  2. 13
      cypress/e2e/core/setup.ts

9
core/src/components/setup/RecommendedApps.vue

@ -38,17 +38,16 @@
<div class="dialog-row">
<NcButton v-if="showInstallButton && !installingApps"
type="tertiary"
role="link"
data-cy-setup-recommended-apps-skip
:href="defaultPageUrl"
data-cy-setup-recommended-apps-skip>
variant="tertiary">
{{ t('core', 'Skip') }}
</NcButton>
<NcButton v-if="showInstallButton"
type="primary"
data-cy-setup-recommended-apps-install
:disabled="installingApps || !isAnyAppSelected"
data-cy-setup-recommended-apps-install>
variant="primary"
@click.stop.prevent="installApps">
{{ installingApps ? t('core', 'Installing apps …') : t('core', 'Install recommended apps') }}
</NcButton>

13
cypress/e2e/core/setup.ts

@ -124,8 +124,19 @@ function sharedSetup() {
cy.location('pathname', { timeout: 10000 })
.should('include', '/core/apps/recommended')
// See the apps setup
cy.get('[data-cy-setup-recommended-apps]')
.should('be.visible')
.within(() => {
cy.findByRole('heading', { name: 'Recommended apps' })
.should('be.visible')
cy.findByRole('link', { name: 'Skip' })
.should('be.visible')
cy.findByRole('button', { name: 'Install recommended apps' })
.should('be.visible')
})
// Skip the setup apps
cy.get('[data-cy-setup-recommended-apps]').should('be.visible')
cy.get('[data-cy-setup-recommended-apps-skip]').click()
// Go to files

Loading…
Cancel
Save