Skip to content

Commit c0a77fd

Browse files
authored
Fix pattern with file path in Compile entries (#308)
1 parent 5182f1f commit c0a77fd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

source/TestAdapter/Discover.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ private static string[] GetAllCsFiles(FileInfo[] nfprojFiles)
215215
var nfprojContent = File.ReadAllText(nfproj.FullName);
216216

217217
// get all Compile items from the project file
218-
string compilePattern = "(?><Compile Include=\")(?<source_file>.+)(?>\")";
218+
string compilePattern = "<Compile Include=\"(?<source_file>[^\"]+)\"";
219219
var compileItems = Regex.Matches(nfprojContent, compilePattern, RegexOptions.IgnoreCase);
220220

221221
foreach (System.Text.RegularExpressions.Match compileItem in compileItems)

0 commit comments

Comments
 (0)