From d1c726f7a751ce0758e86a46698eb2ef61546ff6 Mon Sep 17 00:00:00 2001 From: theroju Date: Thu, 10 Jan 2019 17:09:15 -0500 Subject: [PATCH] Fixed generated TRX file not opening in Visual Studio. --- src/xunit.runner.devices/ResultChannels/TrxResultChannel.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/xunit.runner.devices/ResultChannels/TrxResultChannel.cs b/src/xunit.runner.devices/ResultChannels/TrxResultChannel.cs index 6e0935a..c5c0241 100644 --- a/src/xunit.runner.devices/ResultChannels/TrxResultChannel.cs +++ b/src/xunit.runner.devices/ResultChannels/TrxResultChannel.cs @@ -149,7 +149,7 @@ void ITestListener.RecordResult(TestResultViewModel result) var className = result.TestCase.TestCase.TestMethod.TestClass.Class.Name; resultNode.SetAttribute("testName", testName); resultNode.SetAttribute("testId", id); - resultNode.SetAttribute("duration", result.Duration.ToString("G", CultureInfo.InvariantCulture)); + resultNode.SetAttribute("duration", result.Duration.ToString("c", CultureInfo.InvariantCulture)); resultNode.SetAttribute("computerName", ""); if (result.TestCase.Result == TestState.Failed)