@@ -187,7 +187,7 @@ private bool MatchDocumentsWithSources(string module, AssemblySearchType exclude
187
187
{
188
188
if ( excludeAssembliesWithoutSources . Equals ( AssemblySearchType . MissingAll ) )
189
189
{
190
- bool anyDocumentMatches = MatchDocumentsWithSourcesMissingAll ( metadataReader , module ) ;
190
+ bool anyDocumentMatches = MatchDocumentsWithSourcesMissingAll ( metadataReader ) ;
191
191
192
192
if ( ! anyDocumentMatches )
193
193
{
@@ -211,45 +211,19 @@ private bool MatchDocumentsWithSources(string module, AssemblySearchType exclude
211
211
return true ;
212
212
}
213
213
214
- private IEnumerable < ( string documentName , bool documentExists ) > DocumentSourceMap ( MetadataReader metadataReader , string module = "" )
214
+ private IEnumerable < ( string documentName , bool documentExists ) > DocumentSourceMap ( MetadataReader metadataReader )
215
215
{
216
- var foo = metadataReader . Documents . Select ( docHandle =>
216
+ return metadataReader . Documents . Select ( docHandle =>
217
217
{
218
218
Document document = metadataReader . GetDocument ( docHandle ) ;
219
219
string docName = _sourceRootTranslator . ResolveFilePath ( metadataReader . GetString ( document . Name ) ) ;
220
220
return ( docName , _fileSystem . Exists ( docName ) ) ;
221
221
} ) ;
222
-
223
- var baa = metadataReader . Documents . Select ( docHandle =>
224
- {
225
- Document document = metadataReader . GetDocument ( docHandle ) ;
226
- string docName = _sourceRootTranslator . ResolveFilePath ( metadataReader . GetString ( document . Name ) ) ;
227
- return ( docName , metadataReader . GetString ( document . Name ) ) ;
228
- } ) ;
229
-
230
- if ( module . Contains ( "coverlet.tests.projectsample.empty" ) )
231
- {
232
- //throw new Exception(string.Join(Environment.NewLine,
233
- // baa.Select(x =>
234
- // $"Translator.Name: {x.docName}{Environment.NewLine}MetaData.Name: {x.Item2}{Environment.NewLine}Exists: {_fileSystem.Exists(x.docName)}{Environment.NewLine}SourceRoot: {_sourceRootTranslator.SourceRootMapping.Count}")));
235
-
236
- throw new Exception ( string . Join ( Environment . NewLine ,
237
- new string [ ]
238
- {
239
- $ "Translator.Name: { baa . First ( ) . docName } ",
240
- $ "MetaData.Name: { baa . First ( ) . Item2 } ",
241
- $ "Exists: { _fileSystem . Exists ( baa . First ( ) . docName ) } "
242
- } . Concat ( _sourceRootTranslator . SourceRootMapping . Values . SelectMany ( x => x . Select ( y => $ "ProjectPath: { y . ProjectPath } { Environment . NewLine } OrigPath: { y . OriginalPath } ") ) ) ) ) ;
243
-
244
- }
245
-
246
-
247
- return foo ;
248
222
}
249
223
250
- private bool MatchDocumentsWithSourcesMissingAll ( MetadataReader metadataReader , string module = "" )
224
+ private bool MatchDocumentsWithSourcesMissingAll ( MetadataReader metadataReader )
251
225
{
252
- return DocumentSourceMap ( metadataReader , module ) . Any ( x => x . documentExists ) ;
226
+ return DocumentSourceMap ( metadataReader ) . Any ( x => x . documentExists ) ;
253
227
}
254
228
255
229
private ( bool allDocumentsMatch , string notFoundDocument ) MatchDocumentsWithSourcesMissingAny (
0 commit comments