mirror of
https://github.com/CringeStudios/element-desktop.git
synced 2025-01-31 05:29:58 +01:00
Improve tests to run on arm64 & smoketest seshat (#1668)
This commit is contained in:
parent
74729d1a28
commit
d81521e5ab
27
.github/workflows/build_and_test.yaml
vendored
27
.github/workflows/build_and_test.yaml
vendored
@ -104,7 +104,7 @@ jobs:
|
|||||||
matrix:
|
matrix:
|
||||||
include:
|
include:
|
||||||
- name: macOS Universal
|
- name: macOS Universal
|
||||||
os: macos
|
os: macos-latest
|
||||||
artifact: macos
|
artifact: macos
|
||||||
executable: "/Users/runner/Applications/Element.app/Contents/MacOS/Element"
|
executable: "/Users/runner/Applications/Element.app/Contents/MacOS/Element"
|
||||||
# We need to mount the DMG and copy the app to the Applications folder as a mounted DMG is
|
# We need to mount the DMG and copy the app to the Applications folder as a mounted DMG is
|
||||||
@ -114,26 +114,41 @@ jobs:
|
|||||||
rsync -a /Volumes/Element/Element.app ~/Applications/ &&
|
rsync -a /Volumes/Element/Element.app ~/Applications/ &&
|
||||||
hdiutil detach /Volumes/Element
|
hdiutil detach /Volumes/Element
|
||||||
- name: "Linux (amd64) (sqlcipher: system)"
|
- name: "Linux (amd64) (sqlcipher: system)"
|
||||||
os: ubuntu
|
os: ubuntu-latest
|
||||||
artifact: linux-amd64-sqlcipher-system
|
artifact: linux-amd64-sqlcipher-system
|
||||||
executable: "/opt/Element/element-desktop"
|
executable: "/opt/Element/element-desktop"
|
||||||
prepare_cmd: "sudo apt install ./dist/*.deb"
|
prepare_cmd: "sudo apt install ./dist/*.deb"
|
||||||
- name: "Linux (amd64) (sqlcipher: static)"
|
- name: "Linux (amd64) (sqlcipher: static)"
|
||||||
os: ubuntu
|
os: ubuntu-latest
|
||||||
artifact: linux-amd64-sqlcipher-static
|
artifact: linux-amd64-sqlcipher-static
|
||||||
executable: "/opt/Element/element-desktop"
|
executable: "/opt/Element/element-desktop"
|
||||||
prepare_cmd: "sudo apt install ./dist/*.deb"
|
prepare_cmd: "sudo apt install ./dist/*.deb"
|
||||||
|
- name: "Linux (arm64) (sqlcipher: system)"
|
||||||
|
os: dind-l-arm64
|
||||||
|
artifact: linux-arm64-sqlcipher-system
|
||||||
|
executable: "/opt/Element/element-desktop"
|
||||||
|
prepare_cmd: "sudo apt install -y ./dist/*.deb"
|
||||||
- name: Windows (x86)
|
- name: Windows (x86)
|
||||||
os: windows
|
os: windows-latest
|
||||||
artifact: win-ia32
|
artifact: win-ia32
|
||||||
executable: "./dist/win-ia32-unpacked/Element.exe"
|
executable: "./dist/win-ia32-unpacked/Element.exe"
|
||||||
- name: Windows (x64)
|
- name: Windows (x64)
|
||||||
os: windows
|
os: windows-latest
|
||||||
artifact: win-x64
|
artifact: win-x64
|
||||||
executable: "./dist/win-unpacked/Element.exe"
|
executable: "./dist/win-unpacked/Element.exe"
|
||||||
name: Test ${{ matrix.name }}
|
name: Test ${{ matrix.name }}
|
||||||
runs-on: ${{ matrix.os }}-latest
|
runs-on: ${{ matrix.os }}
|
||||||
steps:
|
steps:
|
||||||
|
# Workaround for self-hosted runners lacking yarn
|
||||||
|
- name: Install Yarn
|
||||||
|
if: runner.environment == 'self-hosted'
|
||||||
|
run: |
|
||||||
|
sudo apt-get -qq update
|
||||||
|
sudo apt-get install -y curl
|
||||||
|
curl -fsSL --create-dirs -o $HOME/bin/yarn https://github.com/yarnpkg/yarn/releases/download/v1.22.19/yarn-1.22.19.js
|
||||||
|
chmod +x $HOME/bin/yarn
|
||||||
|
echo "$HOME/bin" >> $GITHUB_PATH
|
||||||
|
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
- uses: actions/setup-node@v4
|
- uses: actions/setup-node@v4
|
||||||
|
@ -16,12 +16,33 @@ limitations under the License.
|
|||||||
|
|
||||||
import { test, expect } from "../../element-desktop-test";
|
import { test, expect } from "../../element-desktop-test";
|
||||||
|
|
||||||
|
declare global {
|
||||||
|
interface Window {
|
||||||
|
mxPlatformPeg: {
|
||||||
|
get(): {
|
||||||
|
getEventIndexingManager():
|
||||||
|
| {
|
||||||
|
supportsEventIndexing(): Promise<boolean>;
|
||||||
|
}
|
||||||
|
| undefined;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
test.describe("App launch", () => {
|
test.describe("App launch", () => {
|
||||||
test.slow();
|
test.slow();
|
||||||
test("should launch and render the welcome view successfully", async ({ page }) => {
|
test("should launch and render the welcome view successfully and support seshat", async ({ page }) => {
|
||||||
await page.locator("#matrixchat").waitFor();
|
await page.locator("#matrixchat").waitFor();
|
||||||
await page.locator(".mx_Welcome").waitFor();
|
await page.locator(".mx_Welcome").waitFor();
|
||||||
await expect(page).toHaveURL("vector://vector/webapp/#/welcome");
|
await expect(page).toHaveURL("vector://vector/webapp/#/welcome");
|
||||||
await expect(page).toHaveScreenshot();
|
await expect(page).toHaveScreenshot();
|
||||||
|
|
||||||
|
const supported = await page.evaluate<boolean>(async () => {
|
||||||
|
const indexManager = window.mxPlatformPeg.get()?.getEventIndexingManager();
|
||||||
|
return await indexManager?.supportsEventIndexing();
|
||||||
|
});
|
||||||
|
|
||||||
|
expect(supported).toBe(true);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
Before Width: | Height: | Size: 1.2 MiB After Width: | Height: | Size: 1.2 MiB |
Loading…
x
Reference in New Issue
Block a user