Hello, I'm new in rails and I'm developing an application using it.
In one of my model classes I need to set an initial status when I
instantiate it. I override the new method like that:
def Iteration.new
super(:status => 'Não Iniciada')
end
but when in some tests I call the new method passing arguments, It
creates this error:
@iteration = Iteration.new(params[:iteration])
Error message:
test_save_failure(IterationsControllerTest):
ArgumentError: wrong number of arguments(1 for 0)
How can I override one method without ruby tring to override all of then?
Can anybody help me?
Thanks