[rspec-users] testing an action which requires picture

Mano ah lists at ruby-forum.com
Tue Nov 18 01:55:26 EST 2008

 Thank you

  All the above specification passed. Now I want to test the return
 value. I mean

 def scan

     if request.post?

       image = Image.new

       image.blob= params[:image][:blob]

       if image.save_picture

          @code = returns a barcode image value


 What is the rspec code to test the return value and make it pass
Posted via http://www.ruby-forum.com/.

More information about the rspec-users mailing list