Skip to content

Commit

Permalink
Merge branch 'release/9.0.2xx' into SourcePackageUsings
Browse files Browse the repository at this point in the history
  • Loading branch information
tmat authored Dec 11, 2024
2 parents f2a8a80 + 6d67e2a commit ef922fd
Show file tree
Hide file tree
Showing 20 changed files with 8 additions and 100 deletions.
26 changes: 0 additions & 26 deletions src/BuiltInTools/dotnet-format/Commands/FormatCommandCommon.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ internal static class FormatCommandCommon
internal const int UnhandledExceptionExitCode = 1;
internal const int CheckFailedExitCode = 2;
internal const int UnableToLocateMSBuildExitCode = 3;
internal const int UnableToLocateDotNetCliExitCode = 4;

private static string[] VerbosityLevels => new[] { "q", "quiet", "m", "minimal", "n", "normal", "d", "detailed", "diag", "diagnostic" };
private static string[] SeverityLevels => new[] { "info", "warn", "error" };
Expand Down Expand Up @@ -102,14 +101,6 @@ internal static async Task<int> FormatAsync(FormatOptions formatOptions, ILogger
var runtimeVersion = GetRuntimeVersion();
logger.LogDebug(Resources.The_dotnet_runtime_version_is_0, runtimeVersion);

if (!TryGetDotNetCliVersion(out var dotnetVersion))
{
logger.LogError(Resources.Unable_to_locate_dotnet_CLI_Ensure_that_it_is_on_the_PATH);
return UnableToLocateDotNetCliExitCode;
}

logger.LogTrace(Resources.The_dotnet_CLI_version_is_0, dotnetVersion);

if (!TryLoadMSBuild(out var msBuildPath))
{
logger.LogError(Resources.Unable_to_locate_MSBuild_Ensure_the_NET_SDK_was_installed_with_the_official_installer);
Expand Down Expand Up @@ -354,23 +345,6 @@ private static string EnsureTrailingSlash(string path)
?.InformationalVersion;
}

internal static bool TryGetDotNetCliVersion([NotNullWhen(returnValue: true)] out string? dotnetVersion)
{
try
{
var processInfo = ProcessRunner.CreateProcess("dotnet", "--version", captureOutput: true, displayWindow: false);
var versionResult = processInfo.Result.GetAwaiter().GetResult();

dotnetVersion = versionResult.OutputLines[0].Trim();
return true;
}
catch
{
dotnetVersion = null;
return false;
}
}

internal static bool TryLoadMSBuild([NotNullWhen(returnValue: true)] out string? msBuildPath)
{
try
Expand Down
3 changes: 0 additions & 3 deletions src/BuiltInTools/dotnet-format/Resources.resx
Original file line number Diff line number Diff line change
Expand Up @@ -225,9 +225,6 @@
<data name="Standard_input_used_multiple_times" xml:space="preserve">
<value>Standard input markers ('/dev/stdin', '-') can only be used either with `--include` or `--exclude`, but not both.</value>
</data>
<data name="Unable_to_locate_dotnet_CLI_Ensure_that_it_is_on_the_PATH" xml:space="preserve">
<value>Unable to locate dotnet CLI. Ensure that it is on the PATH.</value>
</data>
<data name="The_dotnet_CLI_version_is_0" xml:space="preserve">
<value>The dotnet CLI version is '{0}'.</value>
</data>
Expand Down
5 changes: 0 additions & 5 deletions src/BuiltInTools/dotnet-format/xlf/Resources.cs.xlf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions src/BuiltInTools/dotnet-format/xlf/Resources.de.xlf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions src/BuiltInTools/dotnet-format/xlf/Resources.es.xlf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions src/BuiltInTools/dotnet-format/xlf/Resources.fr.xlf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions src/BuiltInTools/dotnet-format/xlf/Resources.it.xlf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions src/BuiltInTools/dotnet-format/xlf/Resources.ja.xlf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions src/BuiltInTools/dotnet-format/xlf/Resources.ko.xlf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions src/BuiltInTools/dotnet-format/xlf/Resources.pl.xlf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions src/BuiltInTools/dotnet-format/xlf/Resources.pt-BR.xlf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions src/BuiltInTools/dotnet-format/xlf/Resources.ru.xlf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions src/BuiltInTools/dotnet-format/xlf/Resources.tr.xlf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions src/BuiltInTools/dotnet-format/xlf/Resources.zh-Hans.xlf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 0 additions & 5 deletions src/BuiltInTools/dotnet-format/xlf/Resources.zh-Hant.xlf

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ private async Task<List<ITaskItem>> PrepareWorkItem(ITaskItem xunitProject)

var testFilter = string.IsNullOrEmpty(assemblyPartitionInfo.ClassListArgumentString) ? "" : $"--filter \"{assemblyPartitionInfo.ClassListArgumentString}\"";
command = $"{driver} test {assemblyName} -e HELIX_WORK_ITEM_TIMEOUT={timeout} {testExecutionDirectory} {msbuildAdditionalSdkResolverFolder} " +
$"{(XUnitArguments != null ? " " + XUnitArguments : "")} --results-directory .{Path.DirectorySeparatorChar} --logger trx --blame-hang --blame-hang-timeout 30m {testFilter} -- {arguments}";
$"{(XUnitArguments != null ? " " + XUnitArguments : "")} --results-directory .{Path.DirectorySeparatorChar} --logger trx --logger \"console;verbosity=detailed\" --blame-hang --blame-hang-timeout 30m {testFilter} -- {arguments}";

Log.LogMessage($"Creating work item with properties Identity: {assemblyName}, PayloadDirectory: {publishDirectory}, Command: {command}");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -395,12 +395,12 @@ public async Task UploadBlobChunkedAsync_Failure()
api.Verify(api => api.Blob.Upload.UploadChunkAsync(It.IsIn(absoluteUploadUri, uploadPath), It.IsAny<HttpContent>(), It.IsAny<CancellationToken>()), Times.Exactly(1));
}

[Theory(Skip = "https://github.com/dotnet/sdk/issues/42820")]
[InlineData(true, true, true)]
[InlineData(false, true, true)]
[InlineData(true, false, true)]
[InlineData(false, false, true)]
[InlineData(false, false, false)]
[Theory]
public async Task InsecureRegistry(bool isInsecureRegistry, bool serverIsHttps, bool httpServerCloseAbortive)
{
ILogger logger = _loggerFactory.CreateLogger(nameof(InsecureRegistry));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public void It_targets_the_right_shared_framework(string targetFramework, string
}

// Test behavior when implicit version differs for framework-dependent and self-contained apps
[Theory]
[Theory(Skip = "https://github.com/dotnet/sdk/issues/45417")]
[InlineData("netcoreapp1.0", false, true, "1.0.5")]
[InlineData("netcoreapp1.0", true, true, "1.0.16")]
[InlineData("netcoreapp1.0", false, false, "1.0.5")]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ public void compose_dependencies_noopt()
storeDirectory.Should().OnlyHaveFiles(files_on_disk);
}

[Fact]
[Fact(Skip = "https://github.com/dotnet/sdk/issues/45417")]
public void store_nativeonlyassets()
{
TestAsset simpleDependenciesAsset = _testAssetsManager
Expand Down
6 changes: 4 additions & 2 deletions test/dotnet-new.Tests/DotnetNewListTests.Approval.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ namespace Microsoft.DotNet.Cli.New.IntegrationTests
{
public partial class DotnetNewListTests
{
[Theory]
#pragma warning disable xUnit1004 // Test methods should not be skipped
[Theory(Skip = "https://github.com/dotnet/sdk/issues/45406")]
[InlineData("-l")]
[InlineData("--list")]
public Task BasicTest_WhenLegacyCommandIsUsed(string commandName)
Expand All @@ -27,7 +28,7 @@ public Task BasicTest_WhenLegacyCommandIsUsed(string commandName)
.DisableRequireUniquePrefix();
}

[Fact]
[Fact(Skip = "https://github.com/dotnet/sdk/issues/45406")]
public Task BasicTest_WhenListCommandIsUsed()
{
CommandResult commandResult = new DotnetNewCommand(_log, "list")
Expand All @@ -41,6 +42,7 @@ public Task BasicTest_WhenListCommandIsUsed()

return Verify(commandResult.StdOut).UniqueForOSPlatform();
}
#pragma warning restore xUnit1004

[Fact]
public Task Constraints_CanShowMessageIfTemplateGroupIsRestricted()
Expand Down

0 comments on commit ef922fd

Please sign in to comment.