For a proper stub (canned return value, no validation) I prefer the
simple `stub` block syntax:

```
MyThingy.stub(:method) { |arg| 0 }
```

where 0 is, of course, your stubbed return value and |arg| is optional.

...however, your question is confusing. Is the class method in
question on your model or on your controller?

-- 
You received this message because you are subscribed to the Google Groups 
"rspec" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/rspec/CAMf%3DvNoQuCvTtKArHhKXwpLOKdUiA6hmdRaPUbkMFKxNUze9iw%40mail.gmail.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to