[rspec-users] Rspec controller test
dchelimsky at gmail.com
Tue Aug 7 10:43:05 EDT 2007
On 8/7/07, Shaker <flyeminent at hotmail.com> wrote:
> Great Hi to everybody!
> I am currently working on a project which tests the controllers using rspec.
> I came across some methods in the controller which do not generate any
> actions at all. However, they still need testing! Some of these methods do
> require parameters. I am wondering how I can pass the test cases as the
> parameters to these targeted methods in the controller spec?? Below is a
> simple example for illustration:
> in the controller:
> def method_for_test(parameter_1, parameter_2)
> #do some coding
> #no action
> in the controller_spec:
> it "should test the method_for_test" do
> ??how to pass them to method_for_test
> Thank you all in advance.
> View this message in context: http://www.nabble.com/Rspec-controller-test-tf4229016.html#a12030820
> Sent from the rspec-users mailing list archive at Nabble.com.
> rspec-users mailing list
> rspec-users at rubyforge.org
More information about the rspec-users