Remove Cypress & Playwright in their entirety (#12145)
This commit is contained in:
parent
0b6d2f923d
commit
5983528a8d
78 changed files with 73 additions and 5812 deletions
|
@ -139,12 +139,12 @@ test.describe("Audio player", () => {
|
|||
});
|
||||
|
||||
test("should be correctly rendered - light theme", async ({ page, app }) => {
|
||||
await uploadFile(page, "cypress/fixtures/1sec-long-name-audio-file.ogg");
|
||||
await uploadFile(page, "playwright/sample-files/1sec-long-name-audio-file.ogg");
|
||||
await takeSnapshots(page, app, "Selected EventTile of audio player (light theme)");
|
||||
});
|
||||
|
||||
test("should be correctly rendered - light theme with monospace font", async ({ page, app }) => {
|
||||
await uploadFile(page, "cypress/fixtures/1sec-long-name-audio-file.ogg");
|
||||
await uploadFile(page, "playwright/sample-files/1sec-long-name-audio-file.ogg");
|
||||
|
||||
await takeSnapshots(page, app, "Selected EventTile of audio player (light theme, monospace font)", true); // Enable monospace
|
||||
});
|
||||
|
@ -160,7 +160,7 @@ test.describe("Audio player", () => {
|
|||
|
||||
await app.closeDialog();
|
||||
|
||||
await uploadFile(page, "cypress/fixtures/1sec-long-name-audio-file.ogg");
|
||||
await uploadFile(page, "playwright/sample-files/1sec-long-name-audio-file.ogg");
|
||||
|
||||
await takeSnapshots(page, app, "Selected EventTile of audio player (high contrast)");
|
||||
});
|
||||
|
@ -169,13 +169,13 @@ test.describe("Audio player", () => {
|
|||
// Enable dark theme
|
||||
await app.settings.setValue("theme", null, SettingLevel.ACCOUNT, "dark");
|
||||
|
||||
await uploadFile(page, "cypress/fixtures/1sec-long-name-audio-file.ogg");
|
||||
await uploadFile(page, "playwright/sample-files/1sec-long-name-audio-file.ogg");
|
||||
|
||||
await takeSnapshots(page, app, "Selected EventTile of audio player (dark theme)");
|
||||
});
|
||||
|
||||
test("should play an audio file", async ({ page, app }) => {
|
||||
await uploadFile(page, "cypress/fixtures/1sec.ogg");
|
||||
await uploadFile(page, "playwright/sample-files/1sec.ogg");
|
||||
|
||||
// Assert that the audio player is rendered
|
||||
const container = page.locator(".mx_EventTile_last .mx_AudioPlayer_container");
|
||||
|
@ -197,7 +197,7 @@ test.describe("Audio player", () => {
|
|||
});
|
||||
|
||||
test("should support downloading an audio file", async ({ page, app }) => {
|
||||
await uploadFile(page, "cypress/fixtures/1sec.ogg");
|
||||
await uploadFile(page, "playwright/sample-files/1sec.ogg");
|
||||
|
||||
const downloadPromise = page.waitForEvent("download");
|
||||
|
||||
|
@ -212,7 +212,7 @@ test.describe("Audio player", () => {
|
|||
});
|
||||
|
||||
test("should support replying to audio file with another audio file", async ({ page, app }) => {
|
||||
await uploadFile(page, "cypress/fixtures/1sec.ogg");
|
||||
await uploadFile(page, "playwright/sample-files/1sec.ogg");
|
||||
|
||||
// Assert the audio player is rendered
|
||||
await expect(page.locator(".mx_EventTile_last .mx_AudioPlayer_container")).toBeVisible();
|
||||
|
@ -223,7 +223,7 @@ test.describe("Audio player", () => {
|
|||
await tile.getByRole("button", { name: "Reply", exact: true }).click();
|
||||
|
||||
// Reply to the player with another audio file
|
||||
await uploadFile(page, "cypress/fixtures/1sec.ogg");
|
||||
await uploadFile(page, "playwright/sample-files/1sec.ogg");
|
||||
|
||||
// Assert that the audio player is rendered
|
||||
await expect(tile.locator(".mx_AudioPlayer_container")).toBeVisible();
|
||||
|
@ -250,7 +250,7 @@ test.describe("Audio player", () => {
|
|||
await tile.getByRole("button", { name: "Reply", exact: true }).click();
|
||||
};
|
||||
|
||||
await uploadFile(page, "cypress/fixtures/upload-first.ogg");
|
||||
await uploadFile(page, "playwright/sample-files/upload-first.ogg");
|
||||
|
||||
// Assert that the audio player is rendered
|
||||
await expect(page.locator(".mx_EventTile_last .mx_AudioPlayer_container")).toBeVisible();
|
||||
|
@ -258,7 +258,7 @@ test.describe("Audio player", () => {
|
|||
await clickButtonReply();
|
||||
|
||||
// Reply to the player with another audio file
|
||||
await uploadFile(page, "cypress/fixtures/upload-second.ogg");
|
||||
await uploadFile(page, "playwright/sample-files/upload-second.ogg");
|
||||
|
||||
// Assert that the audio player is rendered
|
||||
await expect(page.locator(".mx_EventTile_last .mx_AudioPlayer_container")).toBeVisible();
|
||||
|
@ -266,7 +266,7 @@ test.describe("Audio player", () => {
|
|||
await clickButtonReply();
|
||||
|
||||
// Reply to the player with yet another audio file to create a reply chain
|
||||
await uploadFile(page, "cypress/fixtures/upload-third.ogg");
|
||||
await uploadFile(page, "playwright/sample-files/upload-third.ogg");
|
||||
|
||||
// Assert that the audio player is rendered
|
||||
await expect(tile.locator(".mx_AudioPlayer_container")).toBeVisible();
|
||||
|
@ -299,7 +299,7 @@ test.describe("Audio player", () => {
|
|||
});
|
||||
|
||||
test("should be rendered, play, and support replying on a thread", async ({ page, app }) => {
|
||||
await uploadFile(page, "cypress/fixtures/1sec-long-name-audio-file.ogg");
|
||||
await uploadFile(page, "playwright/sample-files/1sec-long-name-audio-file.ogg");
|
||||
|
||||
// On the main timeline
|
||||
const messageList = page.locator(".mx_RoomView_MessageList");
|
||||
|
|
|
@ -58,9 +58,9 @@ test.describe("FilePanel", () => {
|
|||
|
||||
test("should list tiles on the panel", async ({ page }) => {
|
||||
// Upload multiple files
|
||||
await uploadFile(page, "cypress/fixtures/riot.png"); // Image
|
||||
await uploadFile(page, "cypress/fixtures/1sec.ogg"); // Audio
|
||||
await uploadFile(page, "cypress/fixtures/matrix-org-client-versions.json"); // JSON
|
||||
await uploadFile(page, "playwright/sample-files/riot.png"); // Image
|
||||
await uploadFile(page, "playwright/sample-files/1sec.ogg"); // Audio
|
||||
await uploadFile(page, "playwright/sample-files/matrix-org-client-versions.json"); // JSON
|
||||
|
||||
const roomViewBody = page.locator(".mx_RoomView_body");
|
||||
// Assert that all of the file were uploaded and rendered
|
||||
|
@ -143,7 +143,7 @@ test.describe("FilePanel", () => {
|
|||
|
||||
test("should render the audio player and play the audio file on the panel", async ({ page }) => {
|
||||
// Upload an image file
|
||||
await uploadFile(page, "cypress/fixtures/1sec.ogg");
|
||||
await uploadFile(page, "playwright/sample-files/1sec.ogg");
|
||||
|
||||
const audioBody = page.locator(
|
||||
".mx_FilePanel .mx_RoomView_MessageList .mx_EventTile_mediaLine .mx_MAudioBody .mx_AudioPlayer_container",
|
||||
|
@ -178,7 +178,7 @@ test.describe("FilePanel", () => {
|
|||
const size = "1.12 KB"; // actual file size in kibibytes (1024 bytes)
|
||||
|
||||
// Upload a file
|
||||
await uploadFile(page, "cypress/fixtures/matrix-org-client-versions.json");
|
||||
await uploadFile(page, "playwright/sample-files/matrix-org-client-versions.json");
|
||||
|
||||
const tile = page.locator(".mx_FilePanel .mx_EventTile");
|
||||
// Assert that the file size is displayed in kibibytes, not kilobytes (1000 bytes)
|
||||
|
@ -192,7 +192,7 @@ test.describe("FilePanel", () => {
|
|||
test.describe("download", () => {
|
||||
test("should download an image via the link on the panel", async ({ page, context }) => {
|
||||
// Upload an image file
|
||||
await uploadFile(page, "cypress/fixtures/riot.png");
|
||||
await uploadFile(page, "playwright/sample-files/riot.png");
|
||||
|
||||
// Detect the image file on the panel
|
||||
const imageBody = page.locator(
|
||||
|
|
|
@ -71,7 +71,7 @@ test.describe("Spaces", () => {
|
|||
|
||||
await contextMenu
|
||||
.locator('.mx_SpaceBasicSettings_avatarContainer input[type="file"]')
|
||||
.setInputFiles("cypress/fixtures/riot.png");
|
||||
.setInputFiles("playwright/sample-files/riot.png");
|
||||
await contextMenu.getByRole("textbox", { name: "Name" }).fill("Let's have a Riot");
|
||||
await expect(contextMenu.getByRole("textbox", { name: "Address" })).toHaveValue("lets-have-a-riot");
|
||||
await contextMenu.getByRole("textbox", { name: "Description" }).fill("This is a space to reminisce Riot.im!");
|
||||
|
@ -102,7 +102,7 @@ test.describe("Spaces", () => {
|
|||
|
||||
await menu
|
||||
.locator('.mx_SpaceBasicSettings_avatarContainer input[type="file"]')
|
||||
.setInputFiles("cypress/fixtures/riot.png");
|
||||
.setInputFiles("playwright/sample-files/riot.png");
|
||||
await menu.getByRole("textbox", { name: "Name" }).fill("This is not a Riot");
|
||||
await expect(menu.getByRole("textbox", { name: "Address" })).not.toBeVisible();
|
||||
await menu.getByRole("textbox", { name: "Description" }).fill("This is a private space of mourning Riot.im...");
|
||||
|
@ -147,7 +147,7 @@ test.describe("Spaces", () => {
|
|||
|
||||
await menu
|
||||
.locator('.mx_SpaceBasicSettings_avatarContainer input[type="file"]')
|
||||
.setInputFiles("cypress/fixtures/riot.png");
|
||||
.setInputFiles("playwright/sample-files/riot.png");
|
||||
await expect(menu.getByRole("textbox", { name: "Address" })).not.toBeVisible();
|
||||
await menu.getByRole("textbox", { name: "Description" }).fill("This is a personal space to mourn Riot.im...");
|
||||
await menu.getByRole("textbox", { name: "Name" }).fill("This is my Riot");
|
||||
|
|
|
@ -31,8 +31,8 @@ const AVATAR_SIZE = 30;
|
|||
const AVATAR_RESIZE_METHOD = "crop";
|
||||
|
||||
const ROOM_NAME = "Test room";
|
||||
const OLD_AVATAR = fs.readFileSync("cypress/fixtures/riot.png");
|
||||
const NEW_AVATAR = fs.readFileSync("cypress/fixtures/element.png");
|
||||
const OLD_AVATAR = fs.readFileSync("playwright/sample-files/riot.png");
|
||||
const NEW_AVATAR = fs.readFileSync("playwright/sample-files/element.png");
|
||||
const OLD_NAME = "Alan";
|
||||
const NEW_NAME = "Alan (away)";
|
||||
|
||||
|
@ -139,7 +139,7 @@ test.describe("Timeline", () => {
|
|||
),
|
||||
).toBeVisible();
|
||||
|
||||
// wait for the date separator to appear to have a stable percy snapshot
|
||||
// wait for the date separator to appear to have a stable screenshot
|
||||
await expect(page.locator(".mx_TimelineSeparator")).toHaveText("today");
|
||||
|
||||
await expect(page.locator(".mx_MainSplit")).toMatchScreenshot("configured-room-irc-layout.png");
|
||||
|
@ -684,7 +684,7 @@ test.describe("Timeline", () => {
|
|||
// Upload a file from the message composer
|
||||
await page
|
||||
.locator(".mx_MessageComposer_actions input[type='file']")
|
||||
.setInputFiles("cypress/fixtures/matrix-org-client-versions.json");
|
||||
.setInputFiles("playwright/sample-files/matrix-org-client-versions.json");
|
||||
|
||||
// Click "Upload" button
|
||||
await page.locator(".mx_Dialog").getByRole("button", { name: "Upload" }).click();
|
||||
|
@ -707,7 +707,7 @@ test.describe("Timeline", () => {
|
|||
"**/_matrix/media/v3/thumbnail/matrix.org/2022-08-16_yaiSVSRIsNFfxDnV?*",
|
||||
async (route) => {
|
||||
await route.fulfill({
|
||||
path: "cypress/fixtures/riot.png",
|
||||
path: "playwright/sample-files/riot.png",
|
||||
});
|
||||
},
|
||||
);
|
||||
|
@ -1048,7 +1048,7 @@ test.describe("Timeline", () => {
|
|||
.getByText(OLD_NAME + " created and configured the room."),
|
||||
).toBeVisible();
|
||||
|
||||
// Set the display name to "LONG_STRING 2" in order to avoid a warning in Percy tests from being triggered
|
||||
// Set the display name to "LONG_STRING 2" in order to avoid screenshot tests from failing
|
||||
// due to the generated random mxid being displayed inside the GELS summary.
|
||||
await app.client.setDisplayName(`${LONG_STRING} 2`);
|
||||
|
||||
|
@ -1089,7 +1089,7 @@ test.describe("Timeline", () => {
|
|||
|
||||
// Make sure the strings do not overflow on IRC layout
|
||||
await app.settings.setValue("layout", null, SettingLevel.DEVICE, Layout.IRC);
|
||||
// Scroll to the bottom to have Percy take a snapshot of the whole viewport
|
||||
// Scroll to the bottom to take a snapshot of the whole viewport
|
||||
await app.timeline.scrollToBottom();
|
||||
// Assert that both avatar in the introduction and the last message are visible at the same time
|
||||
await expect(page.locator(".mx_NewRoomIntro .mx_BaseAvatar")).toBeVisible();
|
||||
|
|
|
@ -59,7 +59,7 @@ export class SlidingSyncProxy {
|
|||
|
||||
const postgresId = await this.postgresDocker.run({
|
||||
image: "postgres",
|
||||
containerName: "react-sdk-cypress-sliding-sync-postgres",
|
||||
containerName: "react-sdk-playwright-sliding-sync-postgres",
|
||||
params: ["--rm", "-e", `POSTGRES_PASSWORD=${PG_PASSWORD}`],
|
||||
});
|
||||
|
||||
|
@ -72,7 +72,7 @@ export class SlidingSyncProxy {
|
|||
console.log(new Date(), "starting proxy container...", SLIDING_SYNC_PROXY_TAG);
|
||||
const containerId = await this.proxyDocker.run({
|
||||
image: "ghcr.io/matrix-org/sliding-sync:" + SLIDING_SYNC_PROXY_TAG,
|
||||
containerName: "react-sdk-cypress-sliding-sync-proxy",
|
||||
containerName: "react-sdk-playwright-sliding-sync-proxy",
|
||||
params: [
|
||||
"--rm",
|
||||
"-p",
|
||||
|
|
BIN
playwright/sample-files/1sec-long-name-audio-file.ogg
Executable file
BIN
playwright/sample-files/1sec-long-name-audio-file.ogg
Executable file
Binary file not shown.
BIN
playwright/sample-files/1sec.ogg
Executable file
BIN
playwright/sample-files/1sec.ogg
Executable file
Binary file not shown.
BIN
playwright/sample-files/element.png
Normal file
BIN
playwright/sample-files/element.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 17 KiB |
39
playwright/sample-files/matrix-org-client-versions.json
Normal file
39
playwright/sample-files/matrix-org-client-versions.json
Normal file
|
@ -0,0 +1,39 @@
|
|||
{
|
||||
"versions": [
|
||||
"r0.0.1",
|
||||
"r0.1.0",
|
||||
"r0.2.0",
|
||||
"r0.3.0",
|
||||
"r0.4.0",
|
||||
"r0.5.0",
|
||||
"r0.6.0",
|
||||
"r0.6.1",
|
||||
"v1.1",
|
||||
"v1.2",
|
||||
"v1.3",
|
||||
"v1.4"
|
||||
],
|
||||
"unstable_features": {
|
||||
"org.matrix.label_based_filtering": true,
|
||||
"org.matrix.e2e_cross_signing": true,
|
||||
"org.matrix.msc2432": true,
|
||||
"uk.half-shot.msc2666.mutual_rooms": true,
|
||||
"io.element.e2ee_forced.public": false,
|
||||
"io.element.e2ee_forced.private": false,
|
||||
"io.element.e2ee_forced.trusted_private": false,
|
||||
"org.matrix.msc3026.busy_presence": false,
|
||||
"org.matrix.msc2285.stable": true,
|
||||
"org.matrix.msc3827.stable": true,
|
||||
"org.matrix.msc2716": false,
|
||||
"org.matrix.msc3030": false,
|
||||
"org.matrix.msc3440.stable": true,
|
||||
"org.matrix.msc3771": true,
|
||||
"org.matrix.msc3773": false,
|
||||
"fi.mau.msc2815": false,
|
||||
"org.matrix.msc3882": false,
|
||||
"org.matrix.msc3881": false,
|
||||
"org.matrix.msc3874": false,
|
||||
"org.matrix.msc3886": false,
|
||||
"org.matrix.msc3912": false
|
||||
}
|
||||
}
|
BIN
playwright/sample-files/upload-first.ogg
Executable file
BIN
playwright/sample-files/upload-first.ogg
Executable file
Binary file not shown.
BIN
playwright/sample-files/upload-second.ogg
Executable file
BIN
playwright/sample-files/upload-second.ogg
Executable file
Binary file not shown.
BIN
playwright/sample-files/upload-third.ogg
Executable file
BIN
playwright/sample-files/upload-third.ogg
Executable file
Binary file not shown.
Loading…
Add table
Add a link
Reference in a new issue