File tree Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -723,7 +723,7 @@ public async Task Should_Provide_The_Merged_Result_Using_Project_Settings_Async(
723723 }
724724
725725 [ Test ]
726- public async Task Should_Add_Common_Assembly_Excludes_Includes_Async ( )
726+ public async Task Should_Add_Common_Assembly_Excludes_Includes_Ignoring_Whitespace_Async ( )
727727 {
728728 var mockAppOptions = new Mock < IAppOptions > ( ) ;
729729 mockAppOptions . SetupAllProperties ( ) ;
@@ -732,8 +732,8 @@ public async Task Should_Add_Common_Assembly_Excludes_Includes_Async()
732732 appOptions . Include = new string [ ] { "oldinclude" } ;
733733 appOptions . ModulePathsExclude = new string [ ] { "msexclude" } ;
734734 appOptions . ModulePathsInclude = new string [ ] { "msinclude" } ;
735- appOptions . ExcludeAssemblies = new string [ ] { "excludeassembly" } ;
736- appOptions . IncludeAssemblies = new string [ ] { "includeassembly" } ;
735+ appOptions . ExcludeAssemblies = new string [ ] { "excludeassembly" , " " } ;
736+ appOptions . IncludeAssemblies = new string [ ] { "includeassembly" , " " } ;
737737
738738 var autoMoqer = new AutoMoqer ( ) ;
739739 var coverageProjectSettingsManager = autoMoqer . Create < CoverageProjectSettingsManager > ( ) ;
Original file line number Diff line number Diff line change @@ -58,14 +58,15 @@ private void AddCommonAssemblyExcludesIncludes(IAppOptions appOptions)
5858 }
5959 var newMs = ListFromExisting ( ms ) ;
6060 var newOldStyle = ListFromExisting ( oldStyle ) ;
61-
62- common . ToList ( ) . ForEach ( assemblyFileName =>
61+
62+ var nonWhitespaceCommon = common . Where ( c => ! string . IsNullOrWhiteSpace ( c ) ) ;
63+ foreach ( var assemblyFileName in nonWhitespaceCommon )
6364 {
6465 var msModulePath = $ ".*\\ { assemblyFileName } .dll$";
6566 newMs . Add ( msModulePath ) ;
6667 var old = $ "[{ assemblyFileName } ]*";
6768 newOldStyle . Add ( old ) ;
68- } ) ;
69+ }
6970
7071 return ( newOldStyle . ToArray ( ) , newMs . ToArray ( ) ) ;
7172 }
You can’t perform that action at this time.
0 commit comments