Another newbie...

Using version 3.6 in C#

I need to stub a method that is a Property that has only get defined
such as:
public interface IModel
 {
 ...
   SettingType Setting { get; }
 }

I need to stub this when testing another method

If it is a normal get/set property I can use this syntax:
 target.Setting = SettingType.Foo;
where 'target' is a stub - this works great.

Since it is only a get property, I get syntax errors stating:
Property or indexer 'IModel.Setting' cannot be assigned to -- it is
read only

There's got to be a way to stub this function call!

-- 
You received this message because you are subscribed to the Google Groups 
"Rhino.Mocks" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rhinomocks?hl=en.

Reply via email to