matkoch / resharper-testlinker

Easy navigation between test and production code.
MIT License
28 stars 11 forks source link

Partial namespace support #5

Closed Sam13 closed 7 years ago

Sam13 commented 7 years ago

If I have the following project structure:

ProjectA

ProjectAUnitTest

Currently test linker reports all test classes with the same name and it's impossible to recognize the correct one. image

My proposal is to take parts of namespaces in lookup sequence if multiple occurrences are found. E.g. for Namespace1.Sub1.ClassA lookup for tests with Sub1.ClassA which will find Namespace1UnitTest.Sub1.ClassATest instead of all ClassATest classes

matkoch commented 7 years ago

Hi @Sam13,

sorry for the late response. As far as I remember, this can't be changed from the plugin side. Can't you just use the GoToLinkedTypes action?

Sam13 commented 7 years ago

You mean ReSharper->Navigate->Go to all linked types? Yes that should work as well. So I'll have to update my keyboard shortcut ;-)

matkoch commented 7 years ago

Just for the record, this is the code I'm talking about. I'm just passing the IProjectFile instance there. Formatting happens inside ReSharper :)