Skip to content

Commit

Permalink
test(Modal): update visual tests
Browse files Browse the repository at this point in the history
Screenshots updated with a uniform 12px border-radius.
  • Loading branch information
mvidalgarcia committed Feb 15, 2024
1 parent 9393b22 commit 1ad7766
Show file tree
Hide file tree
Showing 63 changed files with 9 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/orbit-components/src/Modal/Modal.ct-story.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ import Modal, { ModalSection, ModalHeader, ModalFooter } from ".";

const content = "Lorem ispum dolor sit amet.";

export function ModalVisualDefaultStory({ size = SIZES.NORMAL }) {
export function ModalVisualDefaultStory({ size = SIZES.NORMAL, isMobileFullPage = false }) {
return (
<Modal onClose={() => {}} size={size}>
<Modal onClose={() => {}} size={size} isMobileFullPage={isMobileFullPage}>
<ModalHeader
title="Normal header"
illustration={<Illustration name={NAMES[0]} size="small" />}
Expand Down
8 changes: 7 additions & 1 deletion packages/orbit-components/src/Modal/Modal.ct.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,18 @@ import { SIZES } from "./consts";
test.describe("visual Modal", () => {
Object.values(SIZES).forEach(size => {
test(`ModalVisualDefaultStory ${size}`, async ({ mount }) => {
const component = await mount(<ModalVisualDefaultStory />);
const component = await mount(<ModalVisualDefaultStory size={size} />);

await expect(component).toHaveScreenshot();
});
});

test(`ModalVisualDefaultStory isMobileFullPage`, async ({ mount }) => {
const component = await mount(<ModalVisualDefaultStory isMobileFullPage />);

await expect(component).toHaveScreenshot();
});

test("ModalVisualMobileHeader", async ({ mount }) => {
const component = await mount(<ModalVisualMobileHeader />);

Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 1ad7766

Please sign in to comment.