-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added method to specify vague subdirectory matching
- Loading branch information
Showing
14 changed files
with
129 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 17 additions & 3 deletions
20
src/6.0/SpecFlowToMarkdown.Infrastructure.AssemblyLoad/AssemblyScanner.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 3 additions & 2 deletions
5
src/6.0/SpecFlowToMarkdown.Infrastructure.AssemblyLoad/IAssemblyScanner.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
using SpecFlowToMarkdown.Domain.TestAssembly; | ||
using SpecFlowToMarkdown.Domain; | ||
using SpecFlowToMarkdown.Domain.TestAssembly; | ||
|
||
namespace SpecFlowToMarkdown.Infrastructure.AssemblyLoad | ||
{ | ||
public interface IAssemblyScanner | ||
{ | ||
public SpecFlowAssembly Perform(string assemblyPath); | ||
public SpecFlowAssembly Perform(ProgramArguments arguments); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
38 changes: 38 additions & 0 deletions
38
src/6.0/SpecFlowToMarkdown.Infrastructure.Io/FileFinder.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
using System; | ||
using System.IO; | ||
using System.Linq; | ||
using System.Text.RegularExpressions; | ||
using Microsoft.Extensions.Logging; | ||
|
||
namespace SpecFlowToMarkdown.Infrastructure.Io | ||
{ | ||
public class FileFinder : IFileFinder | ||
{ | ||
private readonly ILogger<FileFinder> _logger; | ||
|
||
public FileFinder(ILogger<FileFinder> logger) | ||
{ | ||
_logger = logger; | ||
} | ||
|
||
public string GetFirstFound(string pathName, string fileName) | ||
{ | ||
var foundFilePath = | ||
Directory | ||
.EnumerateFiles( | ||
pathName, | ||
fileName, | ||
SearchOption.AllDirectories | ||
) | ||
.FirstOrDefault(); | ||
|
||
if (foundFilePath == null) | ||
throw new Exception($"Could not find file matching path {pathName} and file {fileName}"); | ||
|
||
_logger | ||
.LogInformation($"Found file path at {foundFilePath}"); | ||
|
||
return foundFilePath; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
namespace SpecFlowToMarkdown.Infrastructure.Io | ||
{ | ||
public interface IFileFinder | ||
{ | ||
string GetFirstFound(string pathName, string fileName); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 3 additions & 2 deletions
5
src/6.0/SpecFlowToMarkdown.Infrastructure.Parsing/Results/ITestExecutionParser.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
using SpecFlowToMarkdown.Domain.Result; | ||
using SpecFlowToMarkdown.Domain; | ||
using SpecFlowToMarkdown.Domain.Result; | ||
|
||
namespace SpecFlowToMarkdown.Infrastructure.Parsing.Results | ||
{ | ||
public interface ITestExecutionParser | ||
{ | ||
public TestExecution Parse(string executionResultsPath); | ||
public TestExecution Parse(ProgramArguments arguments); | ||
} | ||
} |
20 changes: 18 additions & 2 deletions
20
src/6.0/SpecFlowToMarkdown.Infrastructure.Parsing/Results/JsonTestExecutionParser.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters