Skip to content

Commit

Permalink
📝 [open-formulieren/open-forms#4115] Update stories
Browse files Browse the repository at this point in the history
  • Loading branch information
SilviaAmAm committed Apr 19, 2024
1 parent 19d8f48 commit 222ad7f
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions src/components/PostCompletionViews/ConfirmationView.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -101,18 +101,22 @@ export const WithGovMetric = {
},
parameters: {
analyticsToolsParams: {
govmetricSourceId: '1234',
govmetricSourceIdFormFinished: '1234',
govmetricSecureGuid: '',
enableGovmetricAnalytics: true,
},
},
play: async ({canvasElement}) => {
const canvas = within(canvasElement);

const feedbackLink = await canvas.findByRole('link', {name: 'Geef feedback'});
await expect(feedbackLink).toBeVisible();
await expect(feedbackLink.href).toEqual(
'https://websurveys2.govmetric.com/theme/kf/1234?Q_Formid=a-test-form'
const lists = await canvas.getAllByRole('list');
const facesList = lists[0]; // The buttons toolbar is also a list

const faces = within(facesList).getAllByRole('link');

await expect(faces.length).toEqual(3);
await expect(faces[0].href).toEqual(
'https://websurveys2.govmetric.com/theme/kf/1234?Q_Formid=a-test-form&Q_RATINGID=3'
);
},
};

0 comments on commit 222ad7f

Please sign in to comment.