Skip to content

Commit

Permalink
fix: review comments part two
Browse files Browse the repository at this point in the history
  • Loading branch information
MarioCastigliano committed Jul 9, 2024
1 parent 30f8527 commit d3c0e8d
Showing 1 changed file with 22 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -84,18 +84,35 @@ describe(`sbb-radio-button-group`, () => {
);
}

for (const variant of ['vertical', 'horizontal']) {
for (const variant of variants) {
it(
`error message ${variant}`,
`horizontal-from=medium with ${variant.name}`,
visualDiffDefault.with(async (setup) => {
await setup.withFixture(
html`<sbb-radio-button-group allow-empty-selection orientation=${variant}>
${variants[0].template}
<sbb-form-error slot="error">This is a required field.</sbb-form-error>
html`<sbb-radio-button-group orientation="vertical" horizontal-from="medium">
${variant.template}
</sbb-radio-button-group>`,
);
}),
);
}

for (const variant of variants) {
describe(variant.name, () => {
for (const orientation of ['vertical', 'horizontal']) {
it(
`error message orientation=${orientation}`,
visualDiffDefault.with(async (setup) => {
await setup.withFixture(
html`<sbb-radio-button-group allow-empty-selection orientation=${orientation}>
${variant.template}
<sbb-form-error slot="error">This is a required field.</sbb-form-error>
</sbb-radio-button-group>`,
);
}),
);
}
});
}
});
});

0 comments on commit d3c0e8d

Please sign in to comment.