Commit Graph
899 Commits
Author SHA1 Message Date
Gaël Goinvic 0eefcaf31b Merge pull request #1573 from element-hq/gaelg/add-default-mode-assertion
Add default mode tests on mounted volumes
2026-10-14 07:51:13 +02:00
Ben Banfield-Zanin a824b8973a Check that Service references are fully-qualified 2026-10-13 16:25:36 +01:00
Gael Goinvic c3a04b12c6 Change configMap/secrets permissions 2026-10-13 15:00:03 +00:00
Gael Goinvic 22c67cf6bb Enforce 400 mode in configMaps and secrets 2026-10-13 15:00:03 +00:00
Ben Banfield-Zanin d16202e29d Element Web: don't cache /usercontent/ 2026-10-13 13:49:45 +01:00
Johannes Marbach 2c73728420 Ensure the user is joined before hitting /sfu/get in tests 2026-10-13 10:56:58 +02:00
Ben Banfield-Zanin 7f967f798e Merge pull request #1645 from Johennes/fix-proxied-matrix-rtc-tests
Fix lk-jwt-service test for C-S route
2026-10-09 15:37:40 +01:00
Gael Goinvic 7afe226860 Add an asyncio lock on element admin playwright tests 2026-10-09 12:25:28 +00:00
Gael Goinvic fb204c0e0a Collect playwright traces and make them available to CI logs 2026-10-09 08:51:54 +00:00
Gael Goinvic a0350ea6e7 Pass playwright container config files through env vars 2026-10-09 08:23:35 +00:00
Gaël Goinvic 0a23c78284 Merge pull request #1646 from element-hq/gaelg/export-logs
Add docker logs export
2026-10-09 09:24:31 +02:00
Gael Goinvic 6ecb134ee1 Export logs only for containers attached to the k3d network 2026-10-09 07:15:30 +00:00
Gael Goinvic 81a68d93ec Apply hack to skip regular fixture logic before fixtures could throw
This is hidding errors happening during setups, and makes CI difficult
to debug.
2026-10-09 07:02:32 +00:00
Gael Goinvic 291542a67c Add docker logs export 2026-10-08 15:41:50 +00:00
Johannes Marbach 28172a2a50 Fix lk-jwt-service test for C-S route 2026-10-08 16:38:23 +02:00
Gaël Goinvic 38a2aeb65e Merge pull request #1636 from element-hq/gaelg/playwright-remote
Run playwright using a local controller -> remote browser model (running in docker)
2026-10-08 14:14:55 +02:00
Gael Goinvic 7054e51f49 fix top failing when test executes too fast 2026-10-08 12:05:03 +00:00
Ben Banfield-Zanin 3892b7cd58 Merge pull request #1626 from barodeur/msc4140-rtc-appservice-mode
Run the MatrixRTC Authorisation Service as an application service
2026-10-08 11:50:13 +01:00
Paul Chobert 7701332526 Keep 26.9.4 as the last release without the Matrix RTC proxy 2026-10-08 12:28:11 +02:00
Gael Goinvic 4003091423 Use explicit quoted types instead of disabling PEP 649 through future statement 2026-10-08 09:58:05 +00:00
Gael Goinvic e021ec9992 Add top pods to export logs 2026-10-08 09:42:08 +00:00
Gael Goinvic 0c26946ff4 Attach the browser container to the k3d network 2026-10-08 09:32:01 +00:00
Gael Goinvic 96911d886b Allow to install playwright when setting up ess-community-integration-tests externally 2026-10-08 07:07:12 +00:00
Gael Goinvic e4a7d342fe Add back --no-project, dont run playwright tests in external tool call 2026-10-08 07:07:12 +00:00
Paul Chobert bcfd25a3ac Always run the authorisation service as an appservice with MatrixRTC 2026-10-07 18:40:23 +02:00
Gael Goinvic aabe6694c8 Actively wait for the ws connection to succeed 2026-10-07 12:59:49 +00:00
Gael Goinvic 369696b7b5 Simplify the setup playwright controller script by using system node 2026-10-07 12:59:49 +00:00
Gael Goinvic 38efa9d582 Use the setup_playwright_controller.sh script on every hosts 2026-10-07 12:59:49 +00:00
Gael Goinvic 7ca5eab331 Fix container logs 2026-10-07 12:59:48 +00:00
Gael Goinvic 031b850c15 Use docker-bake 2026-10-07 12:59:48 +00:00
Gael Goinvic 8e9f113600 Load CA on image bootstrap 2026-10-07 12:59:48 +00:00
Gael Goinvic e52100e151 Build the playwright image and cache in ghcr.io 2026-10-07 12:59:48 +00:00
Gael Goinvic 7eaee807ad Fix test to latest element-admin version 2026-10-07 12:59:48 +00:00
Gael Goinvic f19ca2d1a4 Use a playwright controller -> browser in docker model 2026-10-07 12:59:47 +00:00
Quentin Gliech d62cff743e Element Admin: Test logging in via MAS in a browser
Covers both an admin user reaching the dashboard and a regular user being
rejected by the MAS policy.
2026-10-07 12:59:47 +00:00
Quentin Gliech 693c088a12 Element Web: Test that it loads and can log in via MAS in a browser 2026-10-07 12:59:47 +00:00
Quentin Gliech 53400891e1 Tests: Add an environment with Element Web, Element Admin and MAS
None of the existing environments deploy either client alongside MAS, so
browser login tests would be skipped everywhere in CI. Well-known
delegation is enabled as Element Admin discovers the homeserver from the
server name.
2026-10-07 12:59:47 +00:00
Quentin Gliech c0bb9fdf82 Tests: Add Playwright browser fixtures
The browser is a headless Chromium shared across the session, with one
isolated context per test. Chromium resolves *.localhost to loopback on
its own so requests reach the k3d ingress the same way the aiohttp based
tests do, and certificate validation is disabled as the test CA isn't in
its trust store.
2026-10-07 12:59:46 +00:00
Quentin Gliech 7dc8b17010 Tests: Add Playwright as an integration tests dependency
Chromium is installed in CI with `playwright install --with-deps` and the
docs explain how to install it locally.
2026-10-07 12:59:46 +00:00
Gael Goinvic fe99adb0b9 Fix flakes when uploading medias
The body is created using the single-use async generator - on retries,
it re-uses the same (consumed) generator object. It caused the request
to abrutly stopped, resulting in Traefik returning HTTP 499 Client
Closed Connection.

The fix makes sure that a new generator is initialized if we have to
retry media upload.
2026-10-07 12:19:16 +00:00
Christian Glombek f64c1ba4c6 Fix the protocol of the Matrix RTC SFU's muxed UDP container port
The SFU declared its `rtc-muxed-udp` container port as TCP. With the
NodePort, LoadBalancer and ClusterIP port types this is only metadata,
because the Service carries the protocol. With `portType: HostPort`
there is no Service, and the container port's protocol decides what the
node forwards: UDP media sent to the host port never reached the SFU,
and clients fell back to the TCP port.

A manifest test now checks that every Service port uses the protocol of
the container port it targets. It fails without this fix for every
values file that exposes the muxed UDP port through a Service.

Assisted-by: AI
Signed-off-by: Christian Glombek <[email protected]>
2026-10-05 12:06:18 +02:00
Paul ChobertandBen Banfield-Zanin b878c9baac Template the registration provided in the values
Like the rest of the configuration provided in the values, the
registration can now refer to the release, e.g. for its proxy_url.

Co-authored-by: Ben Banfield-Zanin <[email protected]>
2026-10-01 16:40:06 +02:00
Paul Chobert 108b61cc3f Skip the proxied Matrix RTC tests only when upgrading from 26.9.4
Like the media upload test in test_synapse.py, only skip in the first
step of the upgrade tests when it deploys a given release, rather than
any release. The release has to be updated before merging.
2026-10-01 16:31:30 +02:00
Paul Chobert 7917f8423b Generate the registration without the chart's Synapse
The homeserver the authorisation service is registered on doesn't have
to be deployed by the chart. Like Hookshot, generate the registration
whenever serverName is set, so that it can be copied from the generated
Secret to the homeserver.

The generated proxy_url only works for a homeserver in the same cluster.
The values comment says how to adapt the registration otherwise.
2026-10-01 15:52:15 +02:00
Paul Chobert 1deffedc54 Make the registration's sender localpart configurable
Add matrixRTC.user.localpart, like the other application services of
the chart (hookshot.user.localpart). It defaults to _lk_jwt_service, the
name used by the lk-jwt-service documentation, and is ignored when
matrixRTC.appserviceRegistration is provided.
2026-10-01 15:36:18 +02:00
Paul Chobert 428623da19 Restrict the registration's users namespace to local users
The authorisation service only acts for users of the homeserver it is
registered on, so its namespace doesn't need to cover remote users.

This follows the registrations of the ESS Pro bots, which use the same
non-exclusive "@.*:<serverName>" regex.
2026-10-01 15:36:17 +02:00
Paul Chobert 0965110afb matrix-rtc: add integration tests for the application service mode
Request a LiveKit token through the endpoint Synapse proxies to the
authorisation service (MSC4512), for a user joined to the room and for
one who isn't. This covers the generated registration being loaded by
Synapse, the proxying, and the room membership check the service makes
with its as_token (MSC4502).

Delegate a delayed leave event through the proxied endpoint for a user
who never connects to the SFU, and check the service sends it on the
user's behalf. This covers the MSC4140 management calls made as an
application service asserting the user.

Both are skipped in the first step of the upgrade tests, which deploys
the chart of the latest release.
2026-09-30 18:01:57 +02:00
Paul Chobert ed2c662a41 matrix-rtc: test the authorisation service appservice registration
Cover the generated registration and its contents, Synapse loading it
with the MSC4502 and MSC4512 experimental features, the authorisation
service environment, and registrations provided inline, via an existing
Secret, or without the chart's Synapse.

Add synapse-matrix-rtc-secrets-{in-helm,externally} values files so the
generic manifest tests also run with a provided registration.
2026-09-30 18:01:56 +02:00
Paul Chobert 47d55e21a8 Add an integration test for MatrixRTC token requests with delegated delayed leave
The only MatrixRTC request covered so far was the deprecated /sfu/get.

Cover /get_token, together with the delegation of the MSC4140 delayed
leave event to the authorisation service, the way Element Call does it
today: with the token request. The user never connects to the SFU, so
the service gives up waiting after `delay_timeout` and sends the leave
event itself, which the test then finds in the room.

The service calls Synapse's delayed event management endpoints without
authentication here. This test will fail if the chart pins a Synapse
which requires authentication on them before the service is able to
authenticate.
2026-09-30 17:06:49 +02:00
Gaël Goinvic ba4ca0445c Merge pull request #1623 from element-hq/gaelg/tests-python-version-314
Fix usage of methods not available before python 3.14
2026-09-29 15:45:54 +02:00