Support the ongoing development of Laravel.io →
posted 10 years ago
Testing

I've rebuilt with the Laravel4 module, and still when I return Redirect::to('/'); (or anywhere for that matter) my functional tests fail, because for whatever reason it wont follow that redirect. After some googling, I found a fix for acceptance tests by setting the browser to something different, but I have no idea if functional tests even use those options since I haven't seen them listed in the yml files.

Has anyone else seen/fixed this?

Last updated 2 years ago.
0

so I've been digging through the output generated by my test, and adding in some other lines of code to see what does and doesn't get executed, and it's looking like it's not that codeception isn't following the redirects, it's that either it's not actually submitting the form when it clicks 'register' or it's hitting the proper url, but not using POST instead of GET.

Last updated 2 years ago.
0

It looks like $I->click('Register'); wasn't working, so in my view I changed my submit button to include an ID of 'register', then changed my test to use $I->click("#register'); instead. Test now passes.

Last updated 2 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2025 Laravel.io - All rights reserved.