fix: refactor OG link builder (#17897)
* fix: manually encode special characters * fix test * fix * fix
This commit is contained in:
1 parent
262738f288
commit
d057d7d37f
5 files changed
+35
-35
No files matched your search
@@ -64,9 +64,10 @@ test.describe("User Avatar", async () => {
|
||||
);
|
||||
// verify objectKey is passed to the OG image
|
||||
// yes, OG image URI encodes at multiple places.. don't want to mess with that.
|
||||
const searchParam = `meetingImage=${encodeURIComponent(`${CAL_URL}/api/avatar/${objectKey}.png`)}`;
|
||||
await expect(page.locator('meta[property="og:image"]')).toHaveAttribute(
|
||||
"content",
|
||||
new RegExp(`meetingImage=${encodeURIComponent(`${CAL_URL}/api/avatar/${objectKey}.png`)}`)
|
||||
new RegExp(encodeURIComponent(searchParam))
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user