Select to view content in your preferred language

Suggestions mocking/testing sealed classes with private setters (like LayerInfo)

533
0
04-22-2011 12:21 PM
BrandonCopeland
Emerging Contributor
I am having a difficult time mocking ESRI.ArcGIS.Client.LayerInfo (and ESRI.ArcGIS.Client.ArcGISDynamicMapServiceLayer) because these class are sealed, implement no interfaces, and have private property setters. I've experimented some with Duck Typing and other adapter like patterns but keep coming up with dead ends. Any suggestions or experience dealing with this issue?

I should also add I am working primarily with MOQ as a mocking framework now but will be taking a look at TypeMock specifically for this issue.
0 Kudos
0 Replies