Fixing bug with no longer finding config files for piped in files #837
validate_pull_request.yml
on: pull_request
Run Tests
1m 34s
Check Formatting
35s
Build CSharpier.MSBuild
1m 46s
Annotations
7 errors and 3 warnings
Should_Format_Multiple_Piped_Files("\n"):
Src/CSharpier.Cli.Tests/CliTests.cs#L252
Expected string to be empty, but found "Error Failed!
Could not find a part of the path '/home/runner/work/csharpier/csharpier/Src/CSharpier.Cli.Tests/bin/Release/net8.0/TestFiles/Test1.cs'.
at System.IO.Enumeration.FileSystemEnumerator`1.CreateDirectoryHandle(String path, Boolean ignoreNotFound)
at System.IO.Enumeration.FileSystemEnumerator`1.Init()
at System.IO.Enumeration.FileSystemEnumerable`1..ctor(String directory, FindTransform transform, EnumerationOptions options, Boolean isNormalized)
at System.IO.Enumeration.FileSystemEnumerableFactory.FileInfos(String directory, String expression, EnumerationOptions options, Boolean isNormalized)
at System.IO.DirectoryInfo.InternalEnumerateInfos(String path, String searchPattern, SearchTarget searchTarget, EnumerationOptions options)
at System.IO.DirectoryInfo.EnumerateFiles(String searchPattern, SearchOption searchOption)
at System.IO.Abstractions.DirectoryInfoWrapper.EnumerateFiles(String searchPattern, SearchOption searchOption)
at CSharpier.Cli.Options.ConfigurationFileOptions.FindForDirectoryName(String directoryName, IFileSystem fileSystem, ILogger logger) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/ConfigurationFileOptions.cs:line 55
at CSharpier.Cli.Options.OptionsProvider.Create(String directoryName, String configPath, IFileSystem fileSystem, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/OptionsProvider.cs:line 45
at CSharpier.Cli.CommandLineFormatter.Format(CommandLineOptions commandLineOptions, IFileSystem fileSystem, IConsole console, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/CommandLineFormatter.cs:line 39
at CSharpier.Cli.Program.PipeMultipleFiles(SystemConsole console, ILogger logger, String configPath, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Program.cs:line 163
Error Failed!
Could not find a part of the path '/home/runner/work/csharpier/csharpier/Src/CSharpier.Cli.Tests/bin/Release/net8.0/TestFiles/Test2.cs'.
at System.IO.Enumeration.FileSystemEnumerator`1.CreateDirectoryHandle(String path, Boolean ignoreNotFound)
at System.IO.Enumeration.FileSystemEnumerator`1.Init()
at System.IO.Enumeration.FileSystemEnumerable`1..ctor(String directory, FindTransform transform, EnumerationOptions options, Boolean isNormalized)
at System.IO.Enumeration.FileSystemEnumerableFactory.FileInfos(String directory, String expression, EnumerationOptions options, Boolean isNormalized)
at System.IO.DirectoryInfo.InternalEnumerateInfos(String path, String searchPattern, SearchTarget searchTarget, EnumerationOptions options)
at System.IO.DirectoryInfo.EnumerateFiles(String searchPattern, SearchOption searchOption)
at System.IO.Abstractions.DirectoryInfoWrapper.EnumerateFiles(String searchPattern, SearchOption searchOption)
at CSharpier.Cli.Options.ConfigurationFileOptions.FindForDirectoryName(String directoryName, IFileSystem fileSystem, ILogger logger) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/ConfigurationFileOptions.cs:line 55
at CSharpier.Cli.Options.OptionsProvider.Create(String directoryName, String configPath, IFileSystem fileSystem, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/OptionsProvider.cs:line 45
at CSharpier.Cli.CommandLineFormatter.Format(CommandLineOptions commandLineOptions, IFileSystem fileSystem, IConsole console, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/CommandLineFormatter.cs:line 39
at CSharpier.Cli.Program.PipeMultipleFiles(SystemConsole console, ILogger logger, String configPath, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Program.cs:line 163
".
|
Should_Format_Multiple_Piped_Files("\r\n"):
Src/CSharpier.Cli.Tests/CliTests.cs#L252
Expected string to be empty, but found "Error Failed!
Could not find a part of the path '/home/runner/work/csharpier/csharpier/Src/CSharpier.Cli.Tests/bin/Release/net8.0/TestFiles/Test1.cs'.
at System.IO.Enumeration.FileSystemEnumerator`1.CreateDirectoryHandle(String path, Boolean ignoreNotFound)
at System.IO.Enumeration.FileSystemEnumerator`1.Init()
at System.IO.Enumeration.FileSystemEnumerable`1..ctor(String directory, FindTransform transform, EnumerationOptions options, Boolean isNormalized)
at System.IO.Enumeration.FileSystemEnumerableFactory.FileInfos(String directory, String expression, EnumerationOptions options, Boolean isNormalized)
at System.IO.DirectoryInfo.InternalEnumerateInfos(String path, String searchPattern, SearchTarget searchTarget, EnumerationOptions options)
at System.IO.DirectoryInfo.EnumerateFiles(String searchPattern, SearchOption searchOption)
at System.IO.Abstractions.DirectoryInfoWrapper.EnumerateFiles(String searchPattern, SearchOption searchOption)
at CSharpier.Cli.Options.ConfigurationFileOptions.FindForDirectoryName(String directoryName, IFileSystem fileSystem, ILogger logger) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/ConfigurationFileOptions.cs:line 55
at CSharpier.Cli.Options.OptionsProvider.Create(String directoryName, String configPath, IFileSystem fileSystem, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/OptionsProvider.cs:line 45
at CSharpier.Cli.CommandLineFormatter.Format(CommandLineOptions commandLineOptions, IFileSystem fileSystem, IConsole console, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/CommandLineFormatter.cs:line 39
at CSharpier.Cli.Program.PipeMultipleFiles(SystemConsole console, ILogger logger, String configPath, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Program.cs:line 163
Error Failed!
Could not find a part of the path '/home/runner/work/csharpier/csharpier/Src/CSharpier.Cli.Tests/bin/Release/net8.0/TestFiles/Test2.cs'.
at System.IO.Enumeration.FileSystemEnumerator`1.CreateDirectoryHandle(String path, Boolean ignoreNotFound)
at System.IO.Enumeration.FileSystemEnumerator`1.Init()
at System.IO.Enumeration.FileSystemEnumerable`1..ctor(String directory, FindTransform transform, EnumerationOptions options, Boolean isNormalized)
at System.IO.Enumeration.FileSystemEnumerableFactory.FileInfos(String directory, String expression, EnumerationOptions options, Boolean isNormalized)
at System.IO.DirectoryInfo.InternalEnumerateInfos(String path, String searchPattern, SearchTarget searchTarget, EnumerationOptions options)
at System.IO.DirectoryInfo.EnumerateFiles(String searchPattern, SearchOption searchOption)
at System.IO.Abstractions.DirectoryInfoWrapper.EnumerateFiles(String searchPattern, SearchOption searchOption)
at CSharpier.Cli.Options.ConfigurationFileOptions.FindForDirectoryName(String directoryName, IFileSystem fileSystem, ILogger logger) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/ConfigurationFileOptions.cs:line 55
at CSharpier.Cli.Options.OptionsProvider.Create(String directoryName, String configPath, IFileSystem fileSystem, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/OptionsProvider.cs:line 45
at CSharpier.Cli.CommandLineFormatter.Format(CommandLineOptions commandLineOptions, IFileSystem fileSystem, IConsole console, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/CommandLineFormatter.cs:line 39
at CSharpier.Cli.Program.PipeMultipleFiles(SystemConsole console, ILogger logger, String configPath, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Program.cs:line 163
".
|
Should_Ignore_Piped_File_With_Multiple_Piped_Files:
Src/CSharpier.Cli.Tests/CliTests.cs#L297
Expected string to be empty, but found "Error Failed!
Could not find a part of the path '/home/runner/work/csharpier/csharpier/Src/CSharpier.Cli.Tests/bin/Release/net8.0/TestFiles/Ignored.cs'.
at System.IO.Enumeration.FileSystemEnumerator`1.CreateDirectoryHandle(String path, Boolean ignoreNotFound)
at System.IO.Enumeration.FileSystemEnumerator`1.Init()
at System.IO.Enumeration.FileSystemEnumerable`1..ctor(String directory, FindTransform transform, EnumerationOptions options, Boolean isNormalized)
at System.IO.Enumeration.FileSystemEnumerableFactory.FileInfos(String directory, String expression, EnumerationOptions options, Boolean isNormalized)
at System.IO.DirectoryInfo.InternalEnumerateInfos(String path, String searchPattern, SearchTarget searchTarget, EnumerationOptions options)
at System.IO.DirectoryInfo.EnumerateFiles(String searchPattern, SearchOption searchOption)
at System.IO.Abstractions.DirectoryInfoWrapper.EnumerateFiles(String searchPattern, SearchOption searchOption)
at CSharpier.Cli.Options.ConfigurationFileOptions.FindForDirectoryName(String directoryName, IFileSystem fileSystem, ILogger logger) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/ConfigurationFileOptions.cs:line 55
at CSharpier.Cli.Options.OptionsProvider.Create(String directoryName, String configPath, IFileSystem fileSystem, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/OptionsProvider.cs:line 45
at CSharpier.Cli.CommandLineFormatter.Format(CommandLineOptions commandLineOptions, IFileSystem fileSystem, IConsole console, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/CommandLineFormatter.cs:line 39
at CSharpier.Cli.Program.PipeMultipleFiles(SystemConsole console, ILogger logger, String configPath, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Program.cs:line 163
".
|
Should_Support_Config_With_Multiple_Piped_Files:
Src/CSharpier.Cli.Tests/CliTests.cs#L313
Expected string to be empty, but found "Error Failed!
Could not find a part of the path '/home/runner/work/csharpier/csharpier/Src/CSharpier.Cli.Tests/bin/Release/net8.0/TestFiles/TooWide.cs'.
at System.IO.Enumeration.FileSystemEnumerator`1.CreateDirectoryHandle(String path, Boolean ignoreNotFound)
at System.IO.Enumeration.FileSystemEnumerator`1.Init()
at System.IO.Enumeration.FileSystemEnumerable`1..ctor(String directory, FindTransform transform, EnumerationOptions options, Boolean isNormalized)
at System.IO.Enumeration.FileSystemEnumerableFactory.FileInfos(String directory, String expression, EnumerationOptions options, Boolean isNormalized)
at System.IO.DirectoryInfo.InternalEnumerateInfos(String path, String searchPattern, SearchTarget searchTarget, EnumerationOptions options)
at System.IO.DirectoryInfo.EnumerateFiles(String searchPattern, SearchOption searchOption)
at System.IO.Abstractions.DirectoryInfoWrapper.EnumerateFiles(String searchPattern, SearchOption searchOption)
at CSharpier.Cli.Options.ConfigurationFileOptions.FindForDirectoryName(String directoryName, IFileSystem fileSystem, ILogger logger) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/ConfigurationFileOptions.cs:line 55
at CSharpier.Cli.Options.OptionsProvider.Create(String directoryName, String configPath, IFileSystem fileSystem, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/OptionsProvider.cs:line 45
at CSharpier.Cli.CommandLineFormatter.Format(CommandLineOptions commandLineOptions, IFileSystem fileSystem, IConsole console, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/CommandLineFormatter.cs:line 39
at CSharpier.Cli.Program.PipeMultipleFiles(SystemConsole console, ILogger logger, String configPath, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Program.cs:line 163
".
|
Should_Write_Error_With_Multiple_Piped_Files("InvalidFile.cs":
Src/CSharpier.Cli.Tests/CliTests.cs#L279
Expected string to be
"Error ./InvalidFile.cs - Failed to compile so was not formatted.
(1,26): error CS1513: } expected
" with a length of 100, but
"Error Failed!
Could not find a part of the path '/home/runner/work/csharpier/csharpier/Src/CSharpier.Cli.Tests/bin/Release/net8.0/TestFiles/InvalidFile.cs'.
at System.IO.Enumeration.FileSystemEnumerator`1.CreateDirectoryHandle(String path, Boolean ignoreNotFound)
at System.IO.Enumeration.FileSystemEnumerator`1.Init()
at System.IO.Enumeration.FileSystemEnumerable`1..ctor(String directory, FindTransform transform, EnumerationOptions options, Boolean isNormalized)
at System.IO.Enumeration.FileSystemEnumerableFactory.FileInfos(String directory, String expression, EnumerationOptions options, Boolean isNormalized)
at System.IO.DirectoryInfo.InternalEnumerateInfos(String path, String searchPattern, SearchTarget searchTarget, EnumerationOptions options)
at System.IO.DirectoryInfo.EnumerateFiles(String searchPattern, SearchOption searchOption)
at System.IO.Abstractions.DirectoryInfoWrapper.EnumerateFiles(String searchPattern, SearchOption searchOption)
at CSharpier.Cli.Options.ConfigurationFileOptions.FindForDirectoryName(String directoryName, IFileSystem fileSystem, ILogger logger) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/ConfigurationFileOptions.cs:line 55
at CSharpier.Cli.Options.OptionsProvider.Create(String directoryName, String configPath, IFileSystem fileSystem, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/OptionsProvider.cs:line 45
at CSharpier.Cli.CommandLineFormatter.Format(CommandLineOptions commandLineOptions, IFileSystem fileSystem, IConsole console, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/CommandLineFormatter.cs:line 39
at CSharpier.Cli.Program.PipeMultipleFiles(SystemConsole console, ILogger logger, String configPath, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Program.cs:line 163
" has a length of 1999, differs near "Fai" (index 6).
|
Should_Write_Error_With_Multiple_Piped_Files("./InvalidFile.cs":
Src/CSharpier.Cli.Tests/CliTests.cs#L279
Expected string to be
"Error ./InvalidFile.cs - Failed to compile so was not formatted.
(1,26): error CS1513: } expected
" with a length of 100, but
"Error Failed!
Could not find a part of the path '/home/runner/work/csharpier/csharpier/Src/CSharpier.Cli.Tests/bin/Release/net8.0/TestFiles/InvalidFile.cs'.
at System.IO.Enumeration.FileSystemEnumerator`1.CreateDirectoryHandle(String path, Boolean ignoreNotFound)
at System.IO.Enumeration.FileSystemEnumerator`1.Init()
at System.IO.Enumeration.FileSystemEnumerable`1..ctor(String directory, FindTransform transform, EnumerationOptions options, Boolean isNormalized)
at System.IO.Enumeration.FileSystemEnumerableFactory.FileInfos(String directory, String expression, EnumerationOptions options, Boolean isNormalized)
at System.IO.DirectoryInfo.InternalEnumerateInfos(String path, String searchPattern, SearchTarget searchTarget, EnumerationOptions options)
at System.IO.DirectoryInfo.EnumerateFiles(String searchPattern, SearchOption searchOption)
at System.IO.Abstractions.DirectoryInfoWrapper.EnumerateFiles(String searchPattern, SearchOption searchOption)
at CSharpier.Cli.Options.ConfigurationFileOptions.FindForDirectoryName(String directoryName, IFileSystem fileSystem, ILogger logger) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/ConfigurationFileOptions.cs:line 55
at CSharpier.Cli.Options.OptionsProvider.Create(String directoryName, String configPath, IFileSystem fileSystem, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Options/OptionsProvider.cs:line 45
at CSharpier.Cli.CommandLineFormatter.Format(CommandLineOptions commandLineOptions, IFileSystem fileSystem, IConsole console, ILogger logger, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/CommandLineFormatter.cs:line 39
at CSharpier.Cli.Program.PipeMultipleFiles(SystemConsole console, ILogger logger, String configPath, CancellationToken cancellationToken) in /home/runner/work/csharpier/csharpier/Src/CSharpier.Cli/Program.cs:line 163
" has a length of 1999, differs near "Fai" (index 6).
|
Run Tests
Process completed with exit code 1.
|
Check Formatting
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
|
Run Tests
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
|
Build CSharpier.MSBuild
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
|