Fix TestHelper not working when no parameters are given #57

Merged
merged 1 commit into from Mar 5, 2013

Conversation

Projects
None yet
3 participants
@oakho
Contributor

oakho commented Mar 5, 2013

I checked out the master with the recent @keithpitt fix to the TestHelper. Everything worked fine expect for requests without parameters, typically, my "get :index" request.

This comes from the fact that when no parameters are given, we set the parameters variable as an empty hash so It loose it's reference to the http_method variable.

Explicitly passing arguments prevent this issue while avoiding tweaking too much the process method.

Tested against rails 3.2.12 and 4.0.0.beta1

@keithpitt

This comment has been minimized.

Show comment Hide comment
@keithpitt

keithpitt Mar 5, 2013

Contributor

Oh lol, yeah. Good call 👍

Contributor

keithpitt commented Mar 5, 2013

Oh lol, yeah. Good call 👍

Sutto added a commit that referenced this pull request Mar 5, 2013

Merge pull request #57 from oakho/fix-testcase-for-rails-4
Fix TestHelper not working when no parameters are given

@Sutto Sutto merged commit 82d9e65 into Sutto:master Mar 5, 2013

@Sutto

This comment has been minimized.

Show comment Hide comment
@Sutto

Sutto Mar 5, 2013

Owner

Thanks!

Owner

Sutto commented Mar 5, 2013

Thanks!

@oakho oakho deleted the oakho:fix-testcase-for-rails-4 branch Mar 5, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment