Skip to content

Commit

Permalink
fix firefox test
Browse files Browse the repository at this point in the history
  • Loading branch information
larsrickert committed Jan 21, 2025
1 parent d514bb7 commit d52b55c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/sit-onyx/src/components/OnyxAvatar/OnyxAvatar.ct.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import OnyxAvatar from "./OnyxAvatar.vue";
const MOCK_CUSTOM_IMAGE =
`<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2" viewBox="0 0 80 80"><path d="M80 8c0-4.415-3.585-8-8-8H8C3.585 0 0 3.585 0 8v64c0 4.415 3.585 8 8 8h64c4.415 0 8-3.585 8-8z" style="fill:#101f2c"/><path d="M48.16 24.48c-1.44-8.17-3.21-14.28-7.18-17.56-3.54-2.93-8.5-3.5-17.09-1.98C7.91 7.75 4.61 13.23 7.84 31.58c2.62 14.87 6.4 20.29 16.3 20.29 2.28 0 4.89-.29 7.89-.82 16.05-2.83 19.36-8.3 16.14-26.58zm-27.8-2.67c0-.12.02-.28.03-.42.68-4.95 2.64-5.5 7.57-5.5 6.58 0 7.88.97 7.88 12.14 0 3.14-.11 5.45-.41 7.18h-.01v.11c-.77 4.27-2.77 4.78-7.45 4.78-6.58 0-7.88-.97-7.88-12.06 0-2.59.07-4.61.26-6.22h.02z" style="fill:#00adba;fill-rule:nonzero" transform="translate(8.42 8.45)scale(1.12783)"/><path d="M48.12 24.46c-1.44-8.15-3.2-14.25-7.17-17.52-3.53-2.92-8.48-3.51-17.05-2-.18.03-.78.14-.95.17l-2.37 15.21c.81-3.96 2.83-4.43 7.37-4.43 6.57 0 7.86.97 7.86 12.11 0 2.78-.09 4.91-.31 6.55l12.62-10.1z" style="fill:url(#a);fill-rule:nonzero" transform="translate(8.42 8.45)scale(1.12783)"/><path d="M7.84 31.5c1.44 8.15 3.13 14.27 7.09 17.54 3.53 2.92 8.48 3.51 17.05 2 .18-.03.78-.14.95-.17l2.37-15.21c-.81 3.96-2.83 4.43-7.37 4.43-6.57 0-7.86-.97-7.86-12.11 0-2.78.09-4.91.31-6.55L7.84 31.51z" style="fill:url(#b);fill-rule:nonzero" transform="translate(8.42 8.45)scale(1.12783)"/><defs><linearGradient id="a" x1="0" x2="1" y1="0" y2="0" gradientTransform="rotate(20 -28.968 63.083)scale(30.27)" gradientUnits="userSpaceOnUse"><stop offset="0" style="stop-color:#018da0;stop-opacity:1"/><stop offset=".14" style="stop-color:#018da0;stop-opacity:1"/><stop offset=".77" style="stop-color:#00adba;stop-opacity:1"/><stop offset="1" style="stop-color:#00adba;stop-opacity:1"/></linearGradient><linearGradient id="b" x1="0" x2="1" y1="0" y2="0" gradientTransform="rotate(-160 21.757 17.96)scale(30.2)" gradientUnits="userSpaceOnUse"><stop offset="0" style="stop-color:#018da0;stop-opacity:1"/><stop offset=".14" style="stop-color:#018da0;stop-opacity:1"/><stop offset=".77" style="stop-color:#00adba;stop-opacity:1"/><stop offset="1" style="stop-color:#00adba;stop-opacity:1"/></linearGradient></defs></svg>` as const;

const MOCK_IMAGE_URL = "/custom-image.svg" as const;
const MOCK_IMAGE_URL = "https://example.com/custom-image.svg" as const;

/**
* @see: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/Segmenter#examples
Expand Down Expand Up @@ -104,7 +104,7 @@ test("should show custom image", async ({ mount, page }) => {
await expect(initials).toBeHidden();

// ARRANGE (should display fallback if image error occurs)
await page.route("https:/does-not-exist", (route) => route.fulfill({ status: 404 }));
await page.route("https://does-not-exist", (route) => route.fulfill({ status: 404 }));

// ACT
await component.update({ props: { src: "https://does-not-exist" } });
Expand Down

0 comments on commit d52b55c

Please sign in to comment.