Can someone provide a strategy/code samples/pointers to test Captcha validations + Authlogic using Shoulda, Factory Girl and Mocha?
For instance, my UsersController is something like:
class UsersController < ApplicationController
validates_captcha
...
def create
...
if captcha_validated?
# code to deal with user attributes
end
...
end
In this case, how do you mock/stub using Shoulda / Factory Girl / Mocha to test valid and invalid responses to the Captcha image?
Appreciate your help, Siva