From a7c039d3146609801bbe3bff46ac0f256fcdbcb4 Mon Sep 17 00:00:00 2001 From: R Midhun Suresh Date: Fri, 15 Dec 2023 20:00:59 +0530 Subject: [PATCH] Fix playwright screenshot update command on linux (#12060) * Change permission for synapse to work * Upgrade playwright --- package.json | 2 +- .../plugins/homeserver/synapse/index.ts | 4 +++ yarn.lock | 28 +++++++++---------- 3 files changed, 19 insertions(+), 15 deletions(-) diff --git a/package.json b/package.json index 791d0610ee..5d2e07a9ce 100644 --- a/package.json +++ b/package.json @@ -156,7 +156,7 @@ "@peculiar/webcrypto": "^1.4.3", "@percy/cli": "^1.11.0", "@percy/cypress": "^3.1.2", - "@playwright/test": "^1.40.0", + "@playwright/test": "^1.40.1", "@testing-library/cypress": "^9.0.0", "@testing-library/dom": "^9.0.0", "@testing-library/jest-dom": "^6.0.0", diff --git a/playwright/plugins/homeserver/synapse/index.ts b/playwright/plugins/homeserver/synapse/index.ts index ffa0205c69..ee789281ef 100644 --- a/playwright/plugins/homeserver/synapse/index.ts +++ b/playwright/plugins/homeserver/synapse/index.ts @@ -84,6 +84,10 @@ async function cfgDirFromTemplate(opts: StartHomeserverOpts): Promise ${outputSigningKey}`); await fse.writeFile(outputSigningKey, `ed25519 x ${signingKey}`); + // Allow anyone to read, write and execute in the /temp/react-sdk-synapsedocker-xxx directory + // so that the DIND setup that we use to update the playwright screenshots work without any issues. + await fse.chmod(tempDir, 0o757); + return { port, baseUrl, diff --git a/yarn.lock b/yarn.lock index b6f11cc26a..2f357f1366 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2249,12 +2249,12 @@ resolved "https://registry.yarnpkg.com/@pkgjs/parseargs/-/parseargs-0.11.0.tgz#a77ea742fab25775145434eb1d2328cf5013ac33" integrity sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg== -"@playwright/test@^1.40.0": - version "1.40.0" - resolved "https://registry.yarnpkg.com/@playwright/test/-/test-1.40.0.tgz#d06c506977dd7863aa16e07f2136351ecc1be6ed" - integrity sha512-PdW+kn4eV99iP5gxWNSDQCbhMaDVej+RXL5xr6t04nbKLCBwYtA046t7ofoczHOm8u6c+45hpDKQVZqtqwkeQg== +"@playwright/test@^1.40.1": + version "1.40.1" + resolved "https://registry.yarnpkg.com/@playwright/test/-/test-1.40.1.tgz#9e66322d97b1d74b9f8718bacab15080f24cde65" + integrity sha512-EaaawMTOeEItCRvfmkI9v6rBkF1svM8wjl/YPRrg2N2Wmp+4qJYkWtJsbew1szfKKDm6fPLy4YAanBhIlf9dWw== dependencies: - playwright "1.40.0" + playwright "1.40.1" "@radix-ui/primitive@1.0.1": version "1.0.1" @@ -8424,17 +8424,17 @@ pkg-dir@^4.2.0: dependencies: find-up "^4.0.0" -playwright-core@1.40.0: - version "1.40.0" - resolved "https://registry.yarnpkg.com/playwright-core/-/playwright-core-1.40.0.tgz#82f61e5504cb3097803b6f8bbd98190dd34bdf14" - integrity sha512-fvKewVJpGeca8t0ipM56jkVSU6Eo0RmFvQ/MaCQNDYm+sdvKkMBBWTE1FdeMqIdumRaXXjZChWHvIzCGM/tA/Q== +playwright-core@1.40.1: + version "1.40.1" + resolved "https://registry.yarnpkg.com/playwright-core/-/playwright-core-1.40.1.tgz#442d15e86866a87d90d07af528e0afabe4c75c05" + integrity sha512-+hkOycxPiV534c4HhpfX6yrlawqVUzITRKwHAmYfmsVreltEl6fAZJ3DPfLMOODw0H3s1Itd6MDCWmP1fl/QvQ== -playwright@1.40.0: - version "1.40.0" - resolved "https://registry.yarnpkg.com/playwright/-/playwright-1.40.0.tgz#2a1824b9fe5c4fe52ed53db9ea68003543a99df0" - integrity sha512-gyHAgQjiDf1m34Xpwzaqb76KgfzYrhK7iih+2IzcOCoZWr/8ZqmdBw+t0RU85ZmfJMgtgAiNtBQ/KS2325INXw== +playwright@1.40.1: + version "1.40.1" + resolved "https://registry.yarnpkg.com/playwright/-/playwright-1.40.1.tgz#a11bf8dca15be5a194851dbbf3df235b9f53d7ae" + integrity sha512-2eHI7IioIpQ0bS1Ovg/HszsN/XKNwEG1kbzSDDmADpclKc7CyqkHw7Mg2JCz/bbCxg25QUPcjksoMW7JcIFQmw== dependencies: - playwright-core "1.40.0" + playwright-core "1.40.1" optionalDependencies: fsevents "2.3.2"