Skip to content

Commit

Permalink
Update NuGet packages
Browse files Browse the repository at this point in the history
  • Loading branch information
Tyrrrz committed May 29, 2024
1 parent c2555e7 commit 0a45746
Show file tree
Hide file tree
Showing 6 changed files with 43 additions and 45 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="CSharpier.MsBuild" Version="0.26.7" PrivateAssets="all" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
<PackageReference Include="xunit" Version="2.6.4" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.6" PrivateAssets="all" />
<PackageReference Include="CSharpier.MsBuild" Version="0.28.2" PrivateAssets="all" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.10.0" />
<PackageReference Include="xunit" Version="2.8.1" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.8.1" PrivateAssets="all" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,12 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="coverlet.collector" Version="6.0.0" PrivateAssets="all" />
<PackageReference Include="CSharpier.MsBuild" Version="0.26.7" PrivateAssets="all" />
<PackageReference Include="coverlet.collector" Version="6.0.2" PrivateAssets="all" />
<PackageReference Include="CSharpier.MsBuild" Version="0.28.2" PrivateAssets="all" />
<PackageReference Include="FluentAssertions" Version="6.12.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
<PackageReference Include="xunit" Version="2.6.4" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.6" PrivateAssets="all" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.10.0" />
<PackageReference Include="xunit" Version="2.8.1" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.8.1" PrivateAssets="all" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,12 @@ params TestResult[] testResults
true,
// lang=xml
$"""
<RunSettings>
<RunConfiguration>
<TargetFrameworkVersion>{targetFrameworkName}</TargetFrameworkVersion>
</RunConfiguration>
</RunSettings>
"""
<RunSettings>
<RunConfiguration>
<TargetFrameworkVersion>{targetFrameworkName}</TargetFrameworkVersion>
</RunConfiguration>
</RunSettings>
"""
)
)
);
Expand All @@ -43,14 +43,14 @@ params TestResult[] testResults
new TestRunStatistics(
new Dictionary<TestOutcome, long>
{
[TestOutcome.Passed] = testResults.Count(
r => r.Outcome == TestOutcome.Passed
[TestOutcome.Passed] = testResults.Count(r =>
r.Outcome == TestOutcome.Passed
),
[TestOutcome.Failed] = testResults.Count(
r => r.Outcome == TestOutcome.Failed
[TestOutcome.Failed] = testResults.Count(r =>
r.Outcome == TestOutcome.Failed
),
[TestOutcome.Skipped] = testResults.Count(
r => r.Outcome == TestOutcome.Skipped
[TestOutcome.Skipped] = testResults.Count(r =>
r.Outcome == TestOutcome.Skipped
),
[TestOutcome.None] = testResults.Count(r => r.Outcome == TestOutcome.None)
}
Expand Down
8 changes: 4 additions & 4 deletions GitHubActionsTestLogger/GitHubActionsTestLogger.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="CSharpier.MsBuild" Version="0.26.7" PrivateAssets="all" />
<PackageReference Include="Microsoft.TestPlatform.ObjectModel" Version="17.8.0" />
<PackageReference Include="CSharpier.MsBuild" Version="0.28.2" PrivateAssets="all" />
<PackageReference Include="Microsoft.TestPlatform.ObjectModel" Version="17.10.0" />
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="8.0.0" PrivateAssets="all" />
<PackageReference Include="PolyShim" Version="1.9.0" PrivateAssets="all" />
<PackageReference Include="RazorBlade" Version="0.5.0" ExcludeAssets="compile;runtime" PrivateAssets="all" />
<PackageReference Include="PolyShim" Version="1.12.0" PrivateAssets="all" />
<PackageReference Include="RazorBlade" Version="0.6.0" ExcludeAssets="compile;runtime" PrivateAssets="all" />
</ItemGroup>

</Project>
9 changes: 4 additions & 5 deletions GitHubActionsTestLogger/TestLoggerContext.cs
Original file line number Diff line number Diff line change
Expand Up @@ -117,11 +117,10 @@ public void HandleTestRunComplete(TestRunCompleteEventArgs args)
);

var testResults = _testResults
.Where(
r =>
r.Outcome == TestOutcome.Failed
|| r.Outcome == TestOutcome.Passed && Options.SummaryIncludePassedTests
|| r.Outcome == TestOutcome.Skipped && Options.SummaryIncludeSkippedTests
.Where(r =>
r.Outcome == TestOutcome.Failed
|| r.Outcome == TestOutcome.Passed && Options.SummaryIncludePassedTests
|| r.Outcome == TestOutcome.Skipped && Options.SummaryIncludeSkippedTests
)
.ToArray();

Expand Down
29 changes: 14 additions & 15 deletions GitHubActionsTestLogger/Utils/Extensions/TestResultExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,21 +28,20 @@ internal static class TestResultExtensions

return StackFrame
.ParseMany(testResult.ErrorStackTrace)
.LastOrDefault(
f =>
// Sync method call
// e.g. MyTests.EnsureOnePlusOneEqualsTwo()
f.MethodCall.StartsWith(
testMethodFullyQualifiedName,
StringComparison.OrdinalIgnoreCase
)
||
// Async method call
// e.g. MyTests.<EnsureOnePlusOneEqualsTwo>d__3.MoveNext()
f.MethodCall.Contains(
'<' + testMethodName + '>',
StringComparison.OrdinalIgnoreCase
)
.LastOrDefault(f =>
// Sync method call
// e.g. MyTests.EnsureOnePlusOneEqualsTwo()
f.MethodCall.StartsWith(
testMethodFullyQualifiedName,
StringComparison.OrdinalIgnoreCase
)
||
// Async method call
// e.g. MyTests.<EnsureOnePlusOneEqualsTwo>d__3.MoveNext()
f.MethodCall.Contains(
'<' + testMethodName + '>',
StringComparison.OrdinalIgnoreCase
)
);
}

Expand Down

0 comments on commit 0a45746

Please sign in to comment.