views:

14

answers:

0

I'm starting to create a PowerShell Provider. To start off, I have a class inheriting from NavigationCmdletProvider.

There's only one protected constructor and it requires an instance of ProviderInfo. Yes, that's ProviderInfo .ctor requiring instance of ProviderInfo.

In creating my first test around this provider, I can't seem to find a way to create a "Mock/Fake/Stub" of this ProviderInfo class to being my tests.

There are some internal constructors that I'm sure PowerShell is using to create instances of these objects.

Is there any factory class in PowerShell that I can call to create an instance of the ProviderInfo class for me?