extension/test/runTest.ts: disable D-Bus comm for test execution
This suppresses the "Failed to connect to the bus" error.
Change-Id: Ie193b92085906121ba337bcf4a3af4428c87b31e
Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/619716
kokoro-CI: kokoro <noreply+kokoro@google.com>
Commit-Queue: Hyang-Ah Hana Kim <hyangah@gmail.com>
Reviewed-by: Hongxiang Jiang <hxjiang@golang.org>
diff --git a/extension/test/runTest.ts b/extension/test/runTest.ts
index 6914b03..711769e 100644
--- a/extension/test/runTest.ts
+++ b/extension/test/runTest.ts
@@ -4,6 +4,9 @@
import { SilentReporter, runTests } from '@vscode/test-electron';
async function main() {
+ // Disable chatty electron's DBUS errors by unsetting this env var.
+ // DBUS is not required. https://github.com/microsoft/vscode-test/issues/127
+ process.env['DBUS_SESSION_BUS_ADDRESS'] = '';
// Use the local toolchain by default
// instead of getting affected by the extension/go.mod go or toolchain directives.
process.env['GOTOOLCHAIN'] = 'local';