From be276f80182fb120d4d9e693c9d72781a5caca3b Mon Sep 17 00:00:00 2001 From: Kenneth Pouncey Date: Tue, 21 Jul 2020 11:34:21 +0200 Subject: [PATCH] [browser][tests] Activate System.Runtime.Extensions UserName tests - Added specific tests for Browser --- .../tests/System/Environment.UserName.cs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/libraries/System.Runtime.Extensions/tests/System/Environment.UserName.cs b/src/libraries/System.Runtime.Extensions/tests/System/Environment.UserName.cs index 947cbef2c789f..2157f63c0250a 100644 --- a/src/libraries/System.Runtime.Extensions/tests/System/Environment.UserName.cs +++ b/src/libraries/System.Runtime.Extensions/tests/System/Environment.UserName.cs @@ -5,7 +5,6 @@ namespace System.Tests { - [ActiveIssue("https://github.com/dotnet/runtime/issues/38164", TestPlatforms.Browser)] public class EnvironmentUserName { [Fact] @@ -36,5 +35,14 @@ public void UserName_MatchesEnvironment_Windows() { Assert.Equal(Environment.GetEnvironmentVariable("USERNAME"), Environment.UserName); } + + [Fact] + [PlatformSpecific(TestPlatforms.Browser)] + public void UserName_MatchesEnvironment_Browser() + { + string name = Environment.UserName; + Assert.False(string.IsNullOrWhiteSpace(name)); + Assert.Equal("Browser", name); + } } }