Commit Graph

2063 Commits

Author SHA1 Message Date
dileepyavan
e7c6e7ebea Sandbox: AllowNetwork option to allow outgoing traffic in sandbox mode. (#313912)
* changes

* changes

* Fix deprecated sandbox setting fallback

* Changes to include workspaceStorage directory for allowRead

* changes

* updating vscode sandbox runtime version

* Cleaning up the PR

* Fix terminal sandbox allow-network config

* fixing tests

* fixing tests

* Centralize terminal sandbox enablement checks

* Update network filter sandbox mode test
2026-05-03 16:58:50 +00:00
Dmitriy Vasyura
4c7f8d0f83 Sanity test fixes (#313421) 2026-04-29 23:05:58 -07:00
Rob Lourens
6fdbdc2548 Fix flaky statusbar smoke test (TOCTOU race in click) (#313141)
* fix: avoid TOCTOU race in smoke test click by using page.click

The smoke test for statusbar 'quick input' was flaky because click() in
PlaywrightDriver used two separate operations:
  1. getElementXY( CDP round-trip to get {x, y}selector)
  2. page.mouse.click(x,  another CDP commandy)

Between these two steps, the page's JS event loop is free to process
queued tasks (~1ms window). In the failing case, the markdown-language-
features extension registers a Language Status '{}' item in the status
bar during this window, shifting the EOL item's x position. The click
then lands on '{}' instead of EOL.

Clicking '{}' invokes ShowTooltipCommand which calls hover.show(true),
trapping keyboard focus in a hover  so the EOL quick input neverwidget
opens and the test times out.

Fix: use page.click(selector) for the common no-offset case. Playwright's
native click waits for the element's bounding box to be stable across
multiple frames before dispatching the click, eliminating the race.

Validated with 50 consecutive runs (0 failures vs. ~1-in-22 before).

Also delete ELECTRON_RUN_AS_NODE from the environment before launching
the test binary. When this env var is set, Electron acts as a plain
Node.js binary and rejects Chromium flags like --remote-debugging-port
that Playwright injects, preventing dev-mode smoke tests from launching.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* address review: fix double-offset bug and reduce page.click timeout

- Fix pre-existing double offset: getElementXY already incorporates both
  xoffset/yoffset into the returned coordinates, so don't add them again
  in mouse.click when both offsets are provided.
- Reduce page.click timeout from 2000ms to 100ms so each poll attempt
  in waitAndClick's retry loop (200  100ms = 20s budget) stays within
  its intended time budget.
- Use xoffset ?? 0 / yoffset ?? 0 instead of falsy checks.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* fix: fall back to legacy click for elements with degenerate bounding box

The previous attempt to use page.click() for all clicks broke smoke tests that
target elements like Monaco's hidden .native-edit-context contenteditable, which
Playwright refuses to interact with (even with force: true) because the element
has a degenerate bounding box. Try page.click first (preserves the TOCTOU fix
for status bar items), then fall back to getElementXY + mouse.click on failure.

(Written by Copilot)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* fix: don't skip Playwright actionability checks on click

Removing 'force: true' from page.click - the actionability checks (specifically
the 'stable' check that waits for the bounding box to be unchanged across 2
frames) are exactly what fixes the original TOCTOU race. Skipping them caused
clicks to fire during layout shifts and not register their handlers properly,
breaking unrelated tests like the Problems View statusbar click.

The fallback to legacy getElementXY + mouse.click still handles elements that
genuinely fail actionability checks (e.g. Monaco's hidden .native-edit-context).

(Written by Copilot)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* fix: narrow TOCTOU guard in statusbar.clickOn instead of broad click() change

Revert the playwrightDriver.click() change (which regressed multiple unrelated CI
tests) and instead add a narrowly-scoped fix in statusbar.clickOn(): for
editor-area status items, poll getElementXY until two consecutive samples are
identical before clicking. This guards against the language status ({}) item
shifting EOL/encoding/etc. between position lookup and click dispatch, without
affecting any other test surface.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* fix: use page.click with stable-coords fallback to eliminate statusbar TOCTOU

Use Playwright's page.click (which re-verifies elementFromPoint immediately
before dispatching, closing the TOCTOU window) for editor-area status bar
items. Fall back to a stable-coordinates click when page.click's actionability
check  the known case is Monaco's .native-edit-context overlayfails
(z-index: -10) which elementFromPoint returns instead of the intended target.
Before the fallback, input state is reset (mouse.move to 0,0 + small wait)
so partial hover/mousedown from the failed attempt don't corrupt subsequent
events.

The stable-coordinates fallback polls getElementXY until two consecutive
samples match, then clicks at those exact  minimising (thoughcoordinates
not eliminating) the TOCTOU window in the fallback path too.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* address review: narrow fallback to pointer-intercept errors, use wait() helper, clarify robustClick docs

- robustClick now only falls back on 'intercepts pointer events' errors;
  all other errors are rethrown so real failures aren't silently masked
- Wrap fallback error to preserve both the original and fallback messages
- Replace raw setTimeout with existing wait() helper
- Clarify Code.robustClick JSDoc: not a polling replacement for waitAndClick

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* simplify: remove unnecessary input-state reset before fallback click

The 'intercepts pointer events' error fires at Playwright's actionability
check phase, before any mouse events are dispatched to the  so therepage
is no partial hover/mousedown state to reset.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-04-30 00:07:57 +00:00
Henning Dieterichs
6b2fbaf804 Fixes component explorer lockfile 2026-04-28 17:18:52 +02:00
dependabot[bot]
3dbb1e8b99 Bump postcss from 8.5.8 to 8.5.12 in /test/monaco (#312766)
Bumps [postcss](https://github.com/postcss/postcss) from 8.5.8 to 8.5.12.
- [Release notes](https://github.com/postcss/postcss/releases)
- [Changelog](https://github.com/postcss/postcss/blob/main/CHANGELOG.md)
- [Commits](https://github.com/postcss/postcss/compare/8.5.8...8.5.12)

---
updated-dependencies:
- dependency-name: postcss
  dependency-version: 8.5.12
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-27 09:20:00 -07:00
Dmitriy Vasyura
2723584a56 Dismiss welcome dialog again. (#312421)
Co-authored-by: Copilot <copilot@github.com>
2026-04-24 21:39:03 +00:00
Dmitriy Vasyura
d143e330f4 Only dismiss the welcome dialog in sanity tests if it is shown (#311702)
* Only dismiss the welcome dialog in sanity tests if it is shown

Co-authored-by: Copilot <copilot@github.com>

* Remove Agents app validation on Linux

* Don't run Agents app tests on stable

Co-authored-by: Copilot <copilot@github.com>

* Keep Agents app testing, but disable validation instead.

* Disable agents app test for stable builds

---------

Co-authored-by: Copilot <copilot@github.com>
2026-04-23 08:11:19 +00:00
Johannes Rieken
ba9d296bbe test: add screenshots for InlineChatZoneWidget and its terminated state (#311925) 2026-04-22 09:04:55 -07:00
Rob Lourens
995d3dce7c Try to make multiroot smoke test less flaky (#311127)
* Try to make multiroot smoke test less flaky

The 'Multiroot > shows results from all folders' smoke test on macOS
browser was failing because openFileQuickAccessAndWait() retries 9 times
in ~160ms with no backoff when it sees 'No matching results'. On a fresh
remote/browser server start, the workspace folders may not have been
attached yet (extension host still starting), so file search legitimately
returns 'No matching results' and all 9 retries fire before the workspace
is ready.

Add an incremental backoff between retries so slow workspace/file-search
initialization on CI has a chance to catch up.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* Update test/automation/src/quickaccess.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-04-17 18:10:47 -07:00
dependabot[bot]
717d2a30e1 Bump hono from 4.12.12 to 4.12.14 in /test/mcp (#310374)
Bumps [hono](https://github.com/honojs/hono) from 4.12.12 to 4.12.14.
- [Release notes](https://github.com/honojs/hono/releases)
- [Commits](https://github.com/honojs/hono/compare/v4.12.12...v4.12.14)

---
updated-dependencies:
- dependency-name: hono
  dependency-version: 4.12.14
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-16 23:21:27 +00:00
Vijay Upadya
602484ad5f Chronicle - local and remote (#308602)
* chronicle

* local and cloud store

* upload vscode events to remote store

* few updates

* consent ui and settings

* few optimizations

* test fix

* feedback updates

* test fix

* check setting to enable cmd

* fix test

* Settings update and tool update

* command update

* Settings update

* merge main

* feedback updates

* setting and test update

* few updates

* updates

* test update

* blocks ci update

* feedback updates

* comment update
2026-04-16 10:31:39 +02:00
Dmitriy Vasyura
8da5adecfc Switch to VS Code ACR and add Agents app coverage (#309834)
Co-authored-by: Copilot <copilot@github.com>
2026-04-15 08:46:31 -04:00
Raymond Zhao
c8f23febaf chore: run npm audit fix (#309902)
* chore: run npm audit fix

* bump build/rspack
2026-04-14 18:05:51 +00:00
Dmitriy Vasyura
19957771a1 Handle Welcome Dialog in DevTunnel Test (#309752)
Co-authored-by: Copilot <copilot@github.com>
2026-04-14 00:27:51 -07:00
Dmitriy Vasyura
9374b64c85 Handle Welcome dialog in sanity tests (#309662)
Co-authored-by: Copilot <copilot@github.com>
2026-04-13 23:29:46 +00:00
Josh Spicer
e764858962 Fix onboarding showing for existing users and sanity test failures (#309303)
* fix: restrict onboarding to first-launch users and fix sanity tests

- Add isNew(StorageScope.APPLICATION) guard to only show onboarding for
  genuinely new users, not existing users upgrading
- Move all guard conditions into tryShowOnboarding() for clarity
- Change ONBOARDING_STORAGE_KEY scope from PROFILE to APPLICATION
- Add --skip-welcome to sanity test Electron launch args to prevent
  onboarding overlay from blocking workspace trust dialog

Fixes onboarding showing for existing users and sanity test timeouts
introduced by PR #307262.

* use getBoolean for ONBOARDING_STORAGE_KEY check
2026-04-12 20:21:01 +02:00
João Moreno
91c7ec5681 fix: unskip chat tests (#309228) 2026-04-12 08:48:56 -07:00
dependabot[bot]
eb014b61a9 Bump hono from 4.12.7 to 4.12.12 in /test/mcp (#308404)
Bumps [hono](https://github.com/honojs/hono) from 4.12.7 to 4.12.12.
- [Release notes](https://github.com/honojs/hono/releases)
- [Commits](https://github.com/honojs/hono/compare/v4.12.7...v4.12.12)

---
updated-dependencies:
- dependency-name: hono
  dependency-version: 4.12.12
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-08 09:21:23 -07:00
dependabot[bot]
4a5375b296 Bump @hono/node-server from 1.19.10 to 1.19.13 in /test/mcp (#308403)
Bumps [@hono/node-server](https://github.com/honojs/node-server) from 1.19.10 to 1.19.13.
- [Release notes](https://github.com/honojs/node-server/releases)
- [Commits](https://github.com/honojs/node-server/compare/v1.19.10...v1.19.13)

---
updated-dependencies:
- dependency-name: "@hono/node-server"
  dependency-version: 1.19.13
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-08 09:21:20 -07:00
Dmitriy Vasyura
567b7d7ff9 Disable flaky win32-x64 dev tunnel sanity test (#308313) 2026-04-07 20:05:23 +00:00
Henning Dieterichs
73ce5edc31 Only block ci for CodeEditor fixture changes 2026-04-07 18:38:44 +02:00
Henning Dieterichs
da22369c0d updates blocks-ci-screenshots.md 2026-04-07 18:38:44 +02:00
João Moreno
3bb4cc19be Merge pull request #302778 from microsoft/joao/copilot-builtin
Ship Copilot as a built-in extension
2026-04-07 17:08:36 +02:00
Henning Dieterichs
7eab2726c1 Update test/componentFixtures/blocks-ci-screenshots.md
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-04-07 15:57:15 +02:00
Henning Dieterichs
e2a4bce63e Fail screenshot CI if fixtures with tag blocks-ci change 2026-04-07 15:57:15 +02:00
Henning Dieterichs
1a6b425b58 removes checked in baseline images, as they are now tracked by the screenshot service 2026-04-07 12:56:06 +02:00
João Moreno
d4bb7b41ba getting ready to merge 2026-04-06 20:18:35 +02:00
João Moreno
75fea1b777 Merge remote-tracking branch 'origin/main' into joao/copilot-builtin 2026-04-05 20:39:32 +02:00
dependabot[bot]
c6ea8bdff7 Bump lodash from 4.17.23 to 4.18.1 in /test/monaco (#307338)
Bumps [lodash](https://github.com/lodash/lodash) from 4.17.23 to 4.18.1.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.23...4.18.1)

---
updated-dependencies:
- dependency-name: lodash
  dependency-version: 4.18.1
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-02 07:55:47 -07:00
Benjamin Pasero
b35fdbeb0d smoke test failure: show results from all folders (fix #306890) (#307186)
* smoke test failure: show results from all folders (fix #306890)

* smoke test failure: show results from all folders (fix #306890)
2026-04-01 09:53:17 -07:00
Henning Dieterichs
cbefeb3643 add logs on failure 2026-04-01 11:51:29 +02:00
Henning Dieterichs
6e701d61b3 Adds playwright component fixture tests 2026-04-01 11:51:29 +02:00
Henning Dieterichs
b533ee4b6e Updates component explorer & adopts rspack for fixture serving (#306484) 2026-04-01 03:25:14 +00:00
João Moreno
43bf17515f fix tests 2026-03-31 21:44:30 +02:00
João Moreno
531a11cb38 Merge remote-tracking branch 'origin/main' into joao/copilot-builtin 2026-03-31 11:51:19 +02:00
Dmitriy Vasyura
3d91bf7907 Enable CLI DevTunnel sanity tests (#305807) 2026-03-31 14:13:23 +11:00
Raymond Zhao
c1f3775929 chore: run npm audit fix (#306509) 2026-03-30 16:32:21 -07:00
dependabot[bot]
8c61afa367 Bump path-to-regexp from 8.2.0 to 8.4.0 in /test/mcp (#305927)
Bumps [path-to-regexp](https://github.com/pillarjs/path-to-regexp) from 8.2.0 to 8.4.0.
- [Release notes](https://github.com/pillarjs/path-to-regexp/releases)
- [Changelog](https://github.com/pillarjs/path-to-regexp/blob/master/History.md)
- [Commits](https://github.com/pillarjs/path-to-regexp/compare/v8.2.0...v8.4.0)

---
updated-dependencies:
- dependency-name: path-to-regexp
  dependency-version: 8.4.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Raymond Zhao <7199958+rzhao271@users.noreply.github.com>
2026-03-30 17:07:01 +00:00
Rob Lourens
23c0b41d69 Enable test/test-integration scripts to take file.test.ts arguments (#306039)
* Enable test/test-integration scripts to take file.test.ts arguments
The agent likes to use them this way, when it doesn't read the skill

Co-authored-by: Copilot <copilot@github.com>

* And this

* Fixes

* update

Co-authored-by: Copilot <copilot@github.com>

---------

Co-authored-by: Copilot <copilot@github.com>
2026-03-29 02:48:59 +00:00
Rob Lourens
c065b175fd Add argument parsing, suite filtering, and grep support to integration test scripts (#305837)
* Add argument parsing, suite filtering, and grep support to integration test scripts

- Add --run, --runGlob, --grep, --suite, and --help argument parsing
- --suite selects extension host test suites (comma-separated, glob patterns)
- --grep forwards test name filter to all runners via MOCHA_GREP env var
- Validate --suite filter matches at least one known suite
- Add MOCHA_GREP support to testrunner.js, CSS and HTML test runners
- Seed user settings to suppress dock bounce notifications
- Always apply *.integrationTest.js glob for node.js tests
- Add integration-tests skill documentation

* Address Copilot review feedback

- Quote cd $ROOT, rm -rf $VSCODEUSERDATADIR, rmdir %VSCODEUSERDATADIR%
- Quote --runGlob pattern to prevent premature glob expansion
- Use GREP_ARGS array for safe grep forwarding in .sh
- Use conditional call with proper quoting for grep in .bat
- Deduplicate suite list into KNOWN_SUITES variable
- Remove unused EXTRA_ARGS and ARGS variables from .bat

* Fix Windows CI: remove unnecessary enabledelayedexpansion

The original script used plain 'setlocal'. Adding 'enabledelayedexpansion'
may affect path resolution behavior on Windows CI. Since no delayed
expansion (\!var\!) syntax is used, revert to the original 'setlocal'.

* Fix Windows CI: capture %~dp0 before call :label corrupts it

In Windows batch, 'call :label' can change what %~dp0 resolves to.
Our should_run_suite subroutine uses 'call :should_run_suite', which
caused %~dp0 to resolve to the wrong directory for extension paths
that appear after the subroutine call. Capture the script directory
once at startup into %SCRIPT_DIR% and use it everywhere.
2026-03-28 11:23:37 +11:00
dependabot[bot]
fca9a7879f Bump picomatch from 4.0.3 to 4.0.4 in /test/mcp (#304949)
Bumps [picomatch](https://github.com/micromatch/picomatch) from 4.0.3 to 4.0.4.
- [Release notes](https://github.com/micromatch/picomatch/releases)
- [Changelog](https://github.com/micromatch/picomatch/blob/master/CHANGELOG.md)
- [Commits](https://github.com/micromatch/picomatch/compare/4.0.3...4.0.4)

---
updated-dependencies:
- dependency-name: picomatch
  dependency-version: 4.0.4
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Raymond Zhao <7199958+rzhao271@users.noreply.github.com>
2026-03-27 14:14:17 -07:00
dependabot[bot]
5933225fdb Bump picomatch from 4.0.3 to 4.0.4 in /test/smoke (#304972)
Bumps [picomatch](https://github.com/micromatch/picomatch) from 4.0.3 to 4.0.4.
- [Release notes](https://github.com/micromatch/picomatch/releases)
- [Changelog](https://github.com/micromatch/picomatch/blob/master/CHANGELOG.md)
- [Commits](https://github.com/micromatch/picomatch/compare/4.0.3...4.0.4)

---
updated-dependencies:
- dependency-name: picomatch
  dependency-version: 4.0.4
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Raymond Zhao <7199958+rzhao271@users.noreply.github.com>
2026-03-27 14:14:13 -07:00
dependabot[bot]
094fdac406 Bump picomatch in /test/automation (#304919)
Bumps  and [picomatch](https://github.com/micromatch/picomatch). These dependencies needed to be updated together.

Updates `picomatch` from 2.3.1 to 2.3.2
- [Release notes](https://github.com/micromatch/picomatch/releases)
- [Changelog](https://github.com/micromatch/picomatch/blob/master/CHANGELOG.md)
- [Commits](https://github.com/micromatch/picomatch/compare/2.3.1...2.3.2)

Updates `picomatch` from 4.0.3 to 4.0.4
- [Release notes](https://github.com/micromatch/picomatch/releases)
- [Changelog](https://github.com/micromatch/picomatch/blob/master/CHANGELOG.md)
- [Commits](https://github.com/micromatch/picomatch/compare/2.3.1...2.3.2)

---
updated-dependencies:
- dependency-name: picomatch
  dependency-version: 2.3.2
  dependency-type: indirect
- dependency-name: picomatch
  dependency-version: 4.0.4
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Raymond Zhao <7199958+rzhao271@users.noreply.github.com>
2026-03-26 21:49:26 +00:00
Dmitriy Vasyura
10f505746f Add retries to sanity tests for dpkg lock errors on Linux (#305235) 2026-03-26 10:45:30 -07:00
João Moreno
f88f49bd9d Merge commit '2b44ec5c3fcd5788a7fb6abaa231c6659018babc' into joao/copilot-builtin 2026-03-23 12:44:45 +01:00
Alexandru Dima
a7e3a4e1e5 fix: remove backslash escaping from terminal command labels (#303856)
* fix: remove escapeMarkdownSyntaxTokens from terminal command labels

Fixes #303844

The command text in ChatTerminalThinkingCollapsibleWrapper was being
escaped with escapeMarkdownSyntaxTokens(), which adds backslashes before
chars like - * # etc. This is unnecessary because the text is always
rendered inside markdown code spans or via .textContent, both of which
treat content as literal.

Also adds a component fixture for the terminal collapsible wrapper to
enable visual regression testing of command label rendering.

* fix: use DOM nodes instead of MarkdownString for sandbox command labels

Addresses review feedback: commands containing backticks (common in
PowerShell) would break the inline-code markdown spans. Now both
sandbox and non-sandbox paths use text nodes + <code> elements with
.textContent, which is always safe for arbitrary command text.

Also adds fixture cases for backtick-containing commands to catch
this class of issue.

* fix: remove colons from fixture names to fix CI artifact paths

* add screenshot baselines for terminal collapsible fixtures
2026-03-22 23:24:40 +09:00
João Moreno
5965338aec chore: skip test "can disable AI features" 2026-03-20 13:48:08 +01:00
Robo
99f2863bfe fix: wire ext host restart through utility process api (#302633) 2026-03-19 11:21:00 +01:00
Dmitriy Vasyura
9de7db1a5c Sanity tests improvements (#302917) 2026-03-18 18:42:27 +00:00
Matt Bierner
cfff60f09d Merge pull request #300860 from mjbvz/dev/mjbvz/heavy-swallow
Re-remove webpack (again again)
2026-03-11 18:14:40 -07:00