Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade xUnit #75068

Merged
merged 12 commits into from
Sep 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 14 additions & 1 deletion .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,19 @@ dotnet_public_api_analyzer.require_api_files = true
# Workaround for https://github.com/dotnet/roslyn/issues/70570
dotnet_diagnostic.IDE0055.severity = warning

# These xUnit analyzers were disabled temporarily to let us move to the
# new xUnit and get past several component governance issues. The
# following issue tracks enabling them
#
# https://github.com/dotnet/roslyn/issues/75093
dotnet_diagnostic.xUnit1012.severity = none
dotnet_diagnostic.xUnit1030.severity = none
dotnet_diagnostic.xUnit1031.severity = none
dotnet_diagnostic.xUnit2005.severity = none
dotnet_diagnostic.xUnit2020.severity = none
dotnet_diagnostic.xUnit2023.severity = none
dotnet_diagnostic.xUnit2029.severity = none

# CSharp code style settings:
[*.cs]
# Newline settings
Expand Down Expand Up @@ -300,4 +313,4 @@ dotnet_diagnostic.RS0057.severity = error
dotnet_diagnostic.RS0058.severity = error
dotnet_diagnostic.RS0059.severity = error
dotnet_diagnostic.RS0060.severity = error
dotnet_diagnostic.RS0061.severity = error
dotnet_diagnostic.RS0061.severity = error
30 changes: 14 additions & 16 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,22 +25,6 @@
"problemMatcher": "$msCompile",
"group": "build"
},
{
"label": "build with analyzers",
"command": "./build.sh",
"type": "shell",
"args": [
"--runAnalyzers"
],
"windows": {
"command": "${workspaceFolder}/build.cmd",
"args": [
"-runAnalyzers"
],
},
"problemMatcher": "$msCompile",
"group": "build"
},
{
"label": "build csc",
"command": "dotnet",
Expand Down Expand Up @@ -83,6 +67,20 @@
"problemMatcher": "$msCompile",
"group": "build"
},
{
jaredpar marked this conversation as resolved.
Show resolved Hide resolved
"label": "build Roslyn.sln with analyzers",
"command": "dotnet",
"type": "shell",
"args": [
"build",
"-p:RunAnalyzersDuringBuild=true",
"-p:GenerateFullPaths=true",
"-tl:off",
"Roslyn.sln"
],
"problemMatcher": "$msCompile",
"group": "build"
},
{
"label": "build current project",
"type": "shell",
Expand Down
28 changes: 14 additions & 14 deletions eng/Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@
<ILAsmPackageVersion>9.0.0-rc.2.24462.10</ILAsmPackageVersion>
<ILDAsmPackageVersion>6.0.0-rtm.21518.12</ILDAsmPackageVersion>
<MicrosoftILVerificationVersion>7.0.0-alpha.1.22060.1</MicrosoftILVerificationVersion>
<MicrosoftTestPlatformVersion>17.5.0</MicrosoftTestPlatformVersion>
<_MicrosoftTestPlatformVersion>17.5.0</_MicrosoftTestPlatformVersion>
<!--
VS .NET Runtime

We should try to keep this version in sync with the version of app-local runtime in VS.
-->
<MicrosoftNetCoreAppRuntimePackagesVersion>8.0.0</MicrosoftNetCoreAppRuntimePackagesVersion>
<MicrosoftWindowsDesktopAppRuntimePackagesVersion>8.0.0</MicrosoftWindowsDesktopAppRuntimePackagesVersion>
<xunitVersion>2.4.1</xunitVersion>
<_xunitVersion>2.6.6</_xunitVersion>
<SqliteVersion>2.1.0</SqliteVersion>
<MicrosoftVisualStudioExtensibilityVersion>17.10.2079</MicrosoftVisualStudioExtensibilityVersion>
</PropertyGroup>
Expand Down Expand Up @@ -142,8 +142,8 @@
-->
<PackageVersion Include="Microsoft.VisualStudio.LanguageServer.Client.Implementation" Version="17.10.72-preview" />
<PackageVersion Include="NuGet.ProjectModel" Version="6.8.0-rc.112" />
<PackageVersion Include="Microsoft.TestPlatform.TranslationLayer" Version="$(MicrosoftTestPlatformVersion)" />
<PackageVersion Include="Microsoft.TestPlatform.ObjectModel" Version="$(MicrosoftTestPlatformVersion)" />
<PackageVersion Include="Microsoft.TestPlatform.TranslationLayer" Version="$(_MicrosoftTestPlatformVersion)" />
<PackageVersion Include="Microsoft.TestPlatform.ObjectModel" Version="$(_MicrosoftTestPlatformVersion)" />
<PackageVersion Include="Microsoft.AspNetCore.Razor.ExternalAccess.RoslynWorkspace" Version="9.0.0-preview.24366.2" />

<!--
Expand Down Expand Up @@ -276,17 +276,17 @@
<PackageVersion Include="InputSimulatorPlus" Version="1.0.7" />
<PackageVersion Include="UIAComWrapper" Version="1.1.0.14" />
<PackageVersion Include="DiffPlex" Version="1.7.2" />
<PackageVersion Include="xunit" Version="$(xunitVersion)" />
<PackageVersion Include="xunit.analyzers" Version="0.12.0-pre.20" />
<PackageVersion Include="xunit.assert" Version="$(xunitVersion)" />
<PackageVersion Include="xunit.core" Version="$(xunitVersion)" />
<PackageVersion Include="Xunit.Combinatorial" Version="1.3.2" />
<PackageVersion Include="xunit.extensibility.core" Version="$(xunitVersion)" />
<PackageVersion Include="xunit.runner.visualstudio" Version="2.4.5" />
<PackageVersion Include="xunit.runner.utility" Version="$(xunitVersion)" />
<PackageVersion Include="xunit" Version="$(_xunitVersion)" />
<PackageVersion Include="xunit.analyzers" Version="1.15.0" />
<PackageVersion Include="xunit.assert" Version="$(_xunitVersion)" />
<PackageVersion Include="xunit.core" Version="$(_xunitVersion)" />
<PackageVersion Include="Xunit.Combinatorial" Version="1.6.24" />
<PackageVersion Include="xunit.extensibility.core" Version="$(_xunitVersion)" />
<PackageVersion Include="xunit.runner.visualstudio" Version="2.4.5 " />
<PackageVersion Include="xunit.runner.utility" Version="$(_xunitVersion)" />
<PackageVersion Include="xunit.abstractions" Version="2.0.3" />
<PackageVersion Include="xunit.extensibility.execution" Version="$(xunitVersion)" />
<PackageVersion Include="XunitXml.TestLogger" Version="2.1.26" />
<PackageVersion Include="xunit.extensibility.execution" Version="$(_xunitVersion)" />
<PackageVersion Include="XunitXml.TestLogger" Version="3.1.17" />
<PackageVersion Include="runtime.win-x64.Microsoft.NETCore.ILDAsm" Version="$(ILDAsmPackageVersion)" />
<PackageVersion Include="runtime.linux-arm64.Microsoft.NETCore.ILDAsm" Version="$(ILDAsmPackageVersion)" />
<PackageVersion Include="runtime.linux-x64.Microsoft.NETCore.ILDAsm" Version="$(ILDAsmPackageVersion)" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,6 @@ private static ArrayBuilder<SymbolDisplayPart> PopulateDisplayParts(
symbol.Accept(visitor);
visitor.Free();
}

return builder;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ namespace System.Runtime.CompilerServices { class AsyncMethodBuilderAttribute :
}

[Fact]
public bool TasklikeA3() => VerifyTaskOverloads("f(async () => 3)",
public void TasklikeA3() => VerifyTaskOverloads("f(async () => 3)",
"f(Func<ValueTask<int>> lambda)",
null);

Expand Down
Loading