Commit Graph

52 Commits

Author SHA1 Message Date
Matt Bierner
abc84e0735 Bump webview fallback commit (#157959)
For #157222
2022-08-11 16:40:05 -07:00
Johannes
0656d21d11 auto-fixed prefer-const violation 2022-06-08 17:49:21 +02:00
Matt Bierner
17c75e1180 Allow reusing webview origins across reloads (#149950)
* Allow reusing webview origins across reloads

Currently webviews are always loaded into a unique origin. This keeps them isolated but also means that we can't benefit from caching across window reloads

This change adds a new `origin` option that you can pass to webviews which controls the origin they use. If this origin is not provided, we use a random one instead

We then save off this origin for webview panels and restore it on window reloads. Webviews restore a little faster on window reload

* Update webview fallback version
2022-05-19 16:07:14 -07:00
Benjamin Pasero
2ada17080c Use playwright for desktop smoke tests (#146692)
* Use `playwright` for desktop smoke tests

* fix distro issues

* tests - enable prefs tests for web
2022-04-04 10:13:08 +02:00
SteVen Batten
24d49c0f84 disable workspace trust in web integration tests 2022-03-11 08:52:55 -08:00
Matt Bierner
c569182d08 Encode webview parent origin in authority
Fixes #144703
2022-03-08 11:28:59 -08:00
Matt Bierner
31b199da9c Bump webview commit 2022-02-15 18:36:12 -08:00
Matt Bierner
82fe581566 Bump webview commit 2022-02-14 13:45:05 -08:00
Martin Aeschlimann
22e5d7274a prepare tests for license terms check 2022-02-09 16:18:37 +01:00
Johannes Rieken
4a130c40ed enable @typescript-eslint/member-delimiter-style, https://github.com/microsoft/vscode/issues/140391 2022-02-02 14:35:33 +01:00
Martin Aeschlimann
f9cac7c28a adopt --server-data-dir 2022-01-21 12:11:47 +01:00
Benjamin Pasero
295984b33b tests - adopt new URL syntax when web is connected to a remote 2022-01-20 15:55:18 +01:00
Benjamin Pasero
13461f8c61 Web: change yarn web to run with our server instead of playground (#139725)
* web - first cut `yarn web` via our server

* properly pipe output

* web - remove traces of web playground

* web - remember last opened workspace for convinience

* use vscode-test-web for server less, clean up web commands

* fix comment

* fix `yarn web`

* rename to code-server

* open system browser

* code-server script: use minimist

* test resolver: use ./scripts/code-server

* integartion tests: fix code-server command name

Co-authored-by: Martin Aeschlimann <martinae@microsoft.com>
2022-01-20 13:48:08 +01:00
Martin Aeschlimann
36089a9229 fix unused import 2022-01-19 19:49:37 +01:00
Martin Aeschlimann
ad928a4e0f adopt server script in integration tests 2022-01-19 18:08:04 +01:00
Benjamin Pasero
9be2757019 🆙 playwright@1.18 (#140767)
* tests - use `@playwright/test@1.18.0-rc1`

* fix bad dependency

* clear more weird ts dependencies
2022-01-15 09:35:39 +01:00
Matt Bierner
9f867c3ed8 Revert service worker usage of MessageChannel (#140351)
* Revert service worker usage of MessageChannel

Reverts 66b6adf035

While I'm not 100% about this, I think 66b6adf035 causes resourses to occasionally not load. I believe this can happen if the service worker is unitilized while the webview remains active. I can't reproduce this myself so it may be related to memory pressure or resource usage, however relying on the service worker not being reinitilized does seem like a potentially bad idea https://stackoverflow.com/questions/34775105/what-causes-the-global-context-of-a-service-worker-to-be-reset

Will investigate if there's another way to achive this since using MessagePort did clean up the code and slightly improve performance

* Bump webview commit versions
2022-01-10 14:22:49 -08:00
Matt Bierner
66b6adf035 Switch webview service-worker to use message channel (#138811)
* Switch webview service-worker to use message channel

This change hooks the service worker used for loading webview resources directly up to the main VS Code process over a message channel. Previously this communication had to go through an extra hop through the webview

This simplifies the logic somewhat (although this change required adding extra logic to exchange the message port). It also improves performance a little

* Update webview content commit version
2021-12-10 16:35:13 -08:00
Benjamin Pasero
ec3ba7a320 smoke - rewrite killing 2021-12-09 07:55:25 +01:00
Matt Bierner
c2f4daf348 Update webview bits version for tests 2021-12-07 16:16:54 -08:00
Benjamin Pasero
18c6692316 tests - print main process pid when killing fails 2021-11-29 13:48:27 +01:00
Matt Bierner
f00c4da8b8 Update default webview commit 2021-11-29 12:27:23 +01:00
Benjamin Pasero
e71b28a444 Smoke test lifecycle changes (#137969)
* rewrite teardown

* 💄

* avoid spam errors

* 💄

* split spawning browser from electron

* await copyExtension

* cleanup

* refactor methods

* cleanup

* cleanup

* cleanup

* 🆙 deps
2021-11-28 10:30:52 +01:00
Benjamin Pasero
1b40be3377 smoke - enable graceful-fs (#137734) 2021-11-23 17:29:08 +01:00
Benjamin Pasero
f9e8dc2095 🆙 playwright 2021-11-04 09:27:22 +01:00
Matt Bierner
bc566d42a1 Try bumping webEndpointUrlTemplate again
Reverts dc1a669906

Also bumps distro to pick up new product.json changes
2021-10-26 15:38:11 -07:00
Matt Bierner
5fc835305a Re-enable webview tests on web (#134300)
* Enable webview tests on web

These tests pass fine on Chrome and webkit. On Firefox, the two about loading resources currently fail

I spent a while trying to debug what is going on with these tests. It seems like the service workers is registered properly but `fetch` is never called on it. Skipping these for now

* Remove only

* Fix test
2021-10-01 12:32:29 -07:00
Matt Bierner
4cd3ec8281 Update commit 2021-08-24 14:15:43 -07:00
Matt Bierner
a70fd2fbf6 Bump default webview commit 2021-08-23 18:46:43 -07:00
Logan Ramos
2ee9010437 Disable telemetry in tests (#130591)
* Disable telemetry in tests

* Remove the console log check
2021-08-11 11:49:23 -04:00
Benjamin Pasero
0390d98a4e web tests - print page errors to console
//cc @lramos15 this would have detected the missing module
2021-08-03 09:10:47 +02:00
Benjamin Pasero
99a831f6e8 web - allow integration tests to open a workspace 2021-07-01 15:38:30 +02:00
João Moreno
a44611d4c6 tests: hide output 2021-06-30 11:07:35 +02:00
Robo
92999c339e fix: setuid helper permission (#126798)
* ci: fix setuid helper binary permission

* ci: allow privilege for CLONE_NEWPID | CLONE_NEWNET

* ci: fix chrome-sandbox permission with rpm

* ci: fix permissions on snap

* ci: download electron earlier for arm builds
2021-06-22 08:42:30 -07:00
João Moreno
3d2dea7a9f fix integration browser tests 2021-06-15 15:15:41 +02:00
Benjamin Pasero
81317867a3 web - disable welcome in smoke tests (fix #126221)
//cc @JacksonKearl
2021-06-15 10:57:29 +02:00
Benjamin Pasero
2ddc1e4fc5 Produce logs during test runs (integration, smoke) and publish as artefacts (#126065)
* first cut upload log files from integration test runs

* always publish log files

* move logs into integration-tests folder

* also produce logs for smoke tests

* store remote log files

* wire in logspath arg properly

* always publish logs

* enable logs for browser based smoke tests

* log only in verbose
2021-06-15 08:33:26 +02:00
Alexandru Dima
b1bc7be9d1 Do not rely on console.log for exiting tests 2021-06-09 21:47:18 +02:00
Matt Bierner
b1823157d5 Fall back to existing published webview commit (#119295) 2021-05-24 22:36:22 -07:00
Benjamin Pasero
e2954beb4b Remove --no-sandbox (#122909)
* linux - remove `--no-sandbox` flag

We should not disable sandbox on Linux.
We only added this to support running on Kernel <= 3.8 where setuid sandbox is used.

* fix ci

* add some docs
2021-05-04 11:18:19 +02:00
Ladislau Szomoru
06730e3e29 Azure DevOps pipeline - generate unique test result names (#105148)
* Set suite name based on environment variable
2020-08-21 15:05:15 +02:00
Benjamin Pasero
869929e8c6 tests - log the actual build used for tests 2020-05-14 17:00:51 +02:00
Benjamin Pasero
9f45c20088 🆙 playwright@0.15.0 (#96218)
* playwright@0.15.0

* close to dumpio: true

* reduce logging
2020-04-27 08:50:50 +02:00
Benjamin Pasero
9bd87e3852 extensions - wire in proposed API enablement (for #92908) 2020-03-30 08:51:48 +02:00
Benjamin Pasero
537a2e783a tests - pass on enable-proposed-api to server 2020-03-27 14:33:47 +01:00
Benjamin Pasero
a7ed9c9572 🆙 playwright@0.11.0 (#90663) 2020-02-14 09:56:08 +01:00
Benjamin Pasero
4b359a57a5 build - address some issues
- run local and remote integration tests separately
- enable playwright on Linux with -no-sandbox trick
2020-02-12 12:07:44 +01:00
Benjamin Pasero
9d9d729655 Web: run integration tests as part of our product builds (fix #83923) 2020-02-10 11:23:00 +01:00
Benjamin Pasero
6a91ae6eb0 test - fix help output for integration too 2020-02-07 16:48:46 +01:00
Benjamin Pasero
3f4e6a4854 test - make integration tests arguments 2020-02-07 16:35:32 +01:00