Fix flaky onboarding test
This commit is contained in:
parent
7193c08311
commit
61a5a4e35e
|
|
@ -1,5 +1,9 @@
|
|||
import { assertStartPage } from '../../../support/helpers';
|
||||
|
||||
const NewsTeasers = {
|
||||
newsTeasers: [],
|
||||
};
|
||||
|
||||
describe('Onboarding', () => {
|
||||
beforeEach(() => {
|
||||
cy.setup();
|
||||
|
|
@ -22,17 +26,21 @@ describe('Onboarding', () => {
|
|||
},
|
||||
};
|
||||
},
|
||||
NewsTeasers: {},
|
||||
NewsTeasers,
|
||||
},
|
||||
});
|
||||
|
||||
cy.visit('/');
|
||||
assertStartPage(true);
|
||||
cy.get('[data-cy=onboarding-next-link]').click();
|
||||
cy.getByDataCy('onboarding-heading').should('contain.text', 'Ihr Lernbereich');
|
||||
cy.get('[data-cy=onboarding-next-link]').click();
|
||||
cy.getByDataCy('onboarding-heading').should('contain.text', 'Ihr Bereich für Zusammenarbeit');
|
||||
cy.get('[data-cy=onboarding-next-link]').click();
|
||||
cy.getByDataCy('onboarding-heading').should('contain.text', 'Ihr persönlicher Bereich');
|
||||
cy.get('[data-cy=onboarding-next-link]').click();
|
||||
assertStartPage(false);
|
||||
cy.wait('@NewsTeasers');
|
||||
});
|
||||
|
||||
it('shows the onboarding steps and skips them', () => {
|
||||
|
|
@ -52,7 +60,7 @@ describe('Onboarding', () => {
|
|||
},
|
||||
};
|
||||
},
|
||||
NewsTeasers: {},
|
||||
NewsTeasers,
|
||||
},
|
||||
});
|
||||
|
||||
|
|
@ -60,6 +68,7 @@ describe('Onboarding', () => {
|
|||
assertStartPage(true);
|
||||
cy.getByDataCy('onboarding-skip-link').click();
|
||||
assertStartPage(false);
|
||||
cy.wait('@NewsTeasers');
|
||||
});
|
||||
|
||||
it('does not show the onboarding', () => {
|
||||
|
|
@ -68,10 +77,12 @@ describe('Onboarding', () => {
|
|||
MeQuery: {
|
||||
me: {},
|
||||
},
|
||||
NewsTeasers,
|
||||
},
|
||||
});
|
||||
|
||||
cy.visit('/');
|
||||
assertStartPage(false);
|
||||
cy.wait('@NewsTeasers');
|
||||
});
|
||||
});
|
||||
|
|
|
|||
|
|
@ -1,7 +1,12 @@
|
|||
<template>
|
||||
<div>
|
||||
<h3 class="onboarding__page-subheading">Einführung: Schritt 1 von 3</h3>
|
||||
<h1 class="onboarding__page-heading">Ihr Lernbereich</h1>
|
||||
<h1
|
||||
data-cy="onboarding-heading"
|
||||
class="onboarding__page-heading"
|
||||
>
|
||||
Ihr Lernbereich
|
||||
</h1>
|
||||
<h2 class="onboarding__heading">
|
||||
{{ $flavor.textTopics }}
|
||||
</h2>
|
||||
|
|
|
|||
|
|
@ -1,7 +1,12 @@
|
|||
<template>
|
||||
<div>
|
||||
<h3 class="onboarding__page-subheading">Einführung: Schritt 2 von 3</h3>
|
||||
<h1 class="onboarding__page-heading">Ihr Bereich für Zusammenarbeit</h1>
|
||||
<h1
|
||||
data-cy="onboarding-heading"
|
||||
class="onboarding__page-heading"
|
||||
>
|
||||
Ihr Bereich für Zusammenarbeit
|
||||
</h1>
|
||||
<h2 class="onboarding__heading">Räume</h2>
|
||||
<p class="onboarding__paragraph">
|
||||
In den Räumen können Sie in grossen und kleinen Gruppen zusammenarbeiten und Beiträge teilen.
|
||||
|
|
|
|||
|
|
@ -1,7 +1,12 @@
|
|||
<template>
|
||||
<div>
|
||||
<h3 class="onboarding__page-subheading">Einführung: Schritt 3 von 3</h3>
|
||||
<h1 class="onboarding__page-heading">Ihr persönlicher Bereich</h1>
|
||||
<h1
|
||||
data-cy="onboarding-heading"
|
||||
class="onboarding__page-heading"
|
||||
>
|
||||
Ihr persönlicher Bereich
|
||||
</h1>
|
||||
<h2 class="onboarding__heading">Portfolio</h2>
|
||||
<p class="onboarding__paragraph">Dokumentieren Sie Ihre Arbeiten und Projekte. Reflektieren Sie Ihr Vorgehen.</p>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Reference in New Issue