Fix for issue #144 ( same as 276 in nunit3-adapter) same fix here.

This commit is contained in:
Terje Sandstrom 2017-03-12 18:19:12 +01:00
Родитель 90c9cab14e
Коммит af60972c0f
1 изменённых файлов: 3 добавлений и 1 удалений

Просмотреть файл

@ -73,10 +73,12 @@ namespace NUnit.VisualStudio.TestAdapter
return navigationData ?? NavigationData.Invalid;
#endif
}
static bool DoesPdbFileExist(string filepath) => File.Exists(Path.ChangeExtension(filepath, ".pdb"));
static IDictionary<string, TypeDefinition> CacheTypes(string assemblyPath)
{
var readerParameters = new ReaderParameters() { ReadSymbols = true };
var readsymbols = DoesPdbFileExist(assemblyPath);
var readerParameters = new ReaderParameters() { ReadSymbols = readsymbols };
var module = ModuleDefinition.ReadModule(assemblyPath, readerParameters);
var types = new Dictionary<string, TypeDefinition>();