diff --git a/src/dotnet/commands/dotnet-sln/LocalizableStrings.resx b/src/dotnet/commands/dotnet-sln/LocalizableStrings.resx index 942139ebe..a2f52ea07 100644 --- a/src/dotnet/commands/dotnet-sln/LocalizableStrings.resx +++ b/src/dotnet/commands/dotnet-sln/LocalizableStrings.resx @@ -150,4 +150,7 @@ Create a solution file. + + Project(s) + \ No newline at end of file diff --git a/src/dotnet/commands/dotnet-sln/list/Program.cs b/src/dotnet/commands/dotnet-sln/list/Program.cs index 3b82bd255..d0dd20eb0 100644 --- a/src/dotnet/commands/dotnet-sln/list/Program.cs +++ b/src/dotnet/commands/dotnet-sln/list/Program.cs @@ -36,9 +36,9 @@ namespace Microsoft.DotNet.Tools.Sln.List } else { - Reporter.Output.WriteLine($"{CommonLocalizableStrings.ProjectReferenceOneOrMore}"); - Reporter.Output.WriteLine(new string('-', CommonLocalizableStrings.ProjectReferenceOneOrMore.Length)); - foreach (var slnProject in slnFile.Projects) + Reporter.Output.WriteLine($"{LocalizableStrings.ProjectsHeader}"); + Reporter.Output.WriteLine(new string('-', LocalizableStrings.ProjectsHeader.Length)); + foreach (var slnProject in slnFile.Projects.Where(p => p.TypeGuid != ProjectTypeGuids.SolutionFolderGuid)) { Reporter.Output.WriteLine(slnProject.FilePath); } diff --git a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.cs.xlf b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.cs.xlf index 88a3a115a..96165f37a 100644 --- a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.cs.xlf +++ b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.cs.xlf @@ -57,6 +57,11 @@ Vytvoří soubor řešení. + + Project(s) + Project(s) + + \ No newline at end of file diff --git a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.de.xlf b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.de.xlf index 8673c2b00..0077f2d30 100644 --- a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.de.xlf +++ b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.de.xlf @@ -57,6 +57,11 @@ Erstellt eine Projektmappendatei. + + Project(s) + Project(s) + + \ No newline at end of file diff --git a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.es.xlf b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.es.xlf index 0a96eadd5..809a3f51e 100644 --- a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.es.xlf +++ b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.es.xlf @@ -57,6 +57,11 @@ Cree un archivo de la solución. + + Project(s) + Project(s) + + \ No newline at end of file diff --git a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.fr.xlf b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.fr.xlf index ad2ad2afd..dc2a8891f 100644 --- a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.fr.xlf +++ b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.fr.xlf @@ -57,6 +57,11 @@ Créez un fichier solution. + + Project(s) + Project(s) + + \ No newline at end of file diff --git a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.it.xlf b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.it.xlf index f59c02961..d4444ea85 100644 --- a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.it.xlf +++ b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.it.xlf @@ -57,6 +57,11 @@ Consente di creare un file di soluzione. + + Project(s) + Project(s) + + \ No newline at end of file diff --git a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.ja.xlf b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.ja.xlf index 09fccb7fc..eba876be4 100644 --- a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.ja.xlf +++ b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.ja.xlf @@ -57,6 +57,11 @@ ソリューション ファイルを作成します。 + + Project(s) + Project(s) + + \ No newline at end of file diff --git a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.ko.xlf b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.ko.xlf index acf0c651c..e6bdc9f31 100644 --- a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.ko.xlf +++ b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.ko.xlf @@ -57,6 +57,11 @@ 솔루션 파일을 만듭니다. + + Project(s) + Project(s) + + \ No newline at end of file diff --git a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.pl.xlf b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.pl.xlf index 3136a922d..0ebb5ff31 100644 --- a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.pl.xlf +++ b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.pl.xlf @@ -57,6 +57,11 @@ Utwórz plik rozwiązania. + + Project(s) + Project(s) + + \ No newline at end of file diff --git a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.pt-BR.xlf b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.pt-BR.xlf index 3cc6b2861..225dac34b 100644 --- a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.pt-BR.xlf +++ b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.pt-BR.xlf @@ -57,6 +57,11 @@ Criar um arquivo de solução. + + Project(s) + Project(s) + + \ No newline at end of file diff --git a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.ru.xlf b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.ru.xlf index 348f82bba..f27ca8a9a 100644 --- a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.ru.xlf +++ b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.ru.xlf @@ -57,6 +57,11 @@ Создает файл решения. + + Project(s) + Project(s) + + \ No newline at end of file diff --git a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.tr.xlf b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.tr.xlf index 92fa7d50a..318a59362 100644 --- a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.tr.xlf +++ b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.tr.xlf @@ -57,6 +57,11 @@ Bir çözüm dosyası oluşturun. + + Project(s) + Project(s) + + \ No newline at end of file diff --git a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.zh-Hans.xlf b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.zh-Hans.xlf index 9b8bc98d6..560874572 100644 --- a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.zh-Hans.xlf +++ b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.zh-Hans.xlf @@ -57,6 +57,11 @@ 创建解决方案文件。 + + Project(s) + Project(s) + + \ No newline at end of file diff --git a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.zh-Hant.xlf b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.zh-Hant.xlf index 95a752f0c..389803b2d 100644 --- a/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.zh-Hant.xlf +++ b/src/dotnet/commands/dotnet-sln/xlf/LocalizableStrings.zh-Hant.xlf @@ -57,6 +57,11 @@ 建立方案檔。 + + Project(s) + Project(s) + + \ No newline at end of file diff --git a/test/dotnet-sln-list.Tests/GivenDotnetSlnList.cs b/test/dotnet-sln-list.Tests/GivenDotnetSlnList.cs index fdc2d9a55..41f0af182 100644 --- a/test/dotnet-sln-list.Tests/GivenDotnetSlnList.cs +++ b/test/dotnet-sln-list.Tests/GivenDotnetSlnList.cs @@ -9,6 +9,7 @@ using System; using System.IO; using System.Linq; using Xunit; +using CommandLocalizableStrings = Microsoft.DotNet.Tools.Sln.LocalizableStrings; namespace Microsoft.DotNet.Cli.Sln.List.Tests { @@ -160,7 +161,7 @@ Commands: } [Fact] - public void WhenNoProjectReferencesArePresentInTheSolutionItPrintsANoProjectMessage() + public void WhenNoProjectsArePresentInTheSolutionItPrintsANoProjectMessage() { var projectDirectory = TestAssets .Get("TestAppWithEmptySln") @@ -177,11 +178,10 @@ Commands: } [Fact] - public void WhenProjectReferencesArePresentInTheSolutionItListsThem() + public void WhenProjectsPresentInTheSolutionItListsThem() { - string OutputText = CommonLocalizableStrings.ProjectReferenceOneOrMore; - OutputText += $@" -{new string('-', OutputText.Length)} + var expectedOutput = $@"{CommandLocalizableStrings.ProjectsHeader} +{new string('-', CommandLocalizableStrings.ProjectsHeader.Length)} {Path.Combine("App", "App.csproj")} {Path.Combine("Lib", "Lib.csproj")}"; @@ -196,7 +196,7 @@ Commands: .WithWorkingDirectory(projectDirectory) .ExecuteWithCapturedOutput("sln list"); cmd.Should().Pass(); - cmd.StdOut.Should().BeVisuallyEquivalentTo(OutputText); + cmd.StdOut.Should().BeVisuallyEquivalentTo(expectedOutput); } } }