From 34a4deb9dedc547f8e84fcbe3c1322db7cd0551f Mon Sep 17 00:00:00 2001 From: David Barbet Date: Fri, 5 Apr 2024 13:06:56 -0700 Subject: [PATCH 1/2] Update VS telemetry for devkit --- eng/Directory.Packages.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eng/Directory.Packages.props b/eng/Directory.Packages.props index 45df3f9cf844a..9351a86a2d912 100644 --- a/eng/Directory.Packages.props +++ b/eng/Directory.Packages.props @@ -102,7 +102,7 @@ - + From b151a6d1da15320bdb330dc7ac0df4a90abdf298 Mon Sep 17 00:00:00 2001 From: David Barbet Date: Mon, 8 Apr 2024 13:42:28 -0700 Subject: [PATCH 2/2] Update unit tests to set required VSTelemetry environment variable --- .../TelemetryReporterTests.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Features/LanguageServer/Microsoft.CodeAnalysis.LanguageServer.UnitTests/TelemetryReporterTests.cs b/src/Features/LanguageServer/Microsoft.CodeAnalysis.LanguageServer.UnitTests/TelemetryReporterTests.cs index 25f175456269d..18ae7694a345c 100644 --- a/src/Features/LanguageServer/Microsoft.CodeAnalysis.LanguageServer.UnitTests/TelemetryReporterTests.cs +++ b/src/Features/LanguageServer/Microsoft.CodeAnalysis.LanguageServer.UnitTests/TelemetryReporterTests.cs @@ -20,6 +20,9 @@ private async Task CreateReporterAsync() { var exportProvider = await LanguageServerTestComposition.CreateExportProviderAsync(TestOutputLogger.Factory, includeDevKitComponents: true, out var _); + // VS Telemetry requires this environment variable to be set. + Environment.SetEnvironmentVariable("CommonPropertyBagPath", Path.GetTempFileName()); + var reporter = exportProvider.GetExport().Value; Assert.NotNull(reporter);