You can clone with
HTTPS or Subversion.
When using a standalone Controller, If I run FunctionalTest->submitForm() twice, the second call will erroneously return a 404 because of a malformed form action attribute.
Rough test code:
// Test a double signup can't happen
// $response gives you a SS_HTTPResponse with a form with an action pointing to MemberModuleTestController/LoginGatewayForm
$response = $this->submitForm('LoginGatewayForm_LoginGatewayForm', 'action_checkEmailAction', array(
'Email' => $nonExistentEmail,
// $response gives you a SS_HTTPResponse with a 404 body
$response = $this->submitForm('LoginGatewayForm_LoginGatewayForm', 'action_registerAction', array(
'Email' => $signupEmail,
'Password' => $signupPassword,
My custom form doesn't do anything weird with the FormAction attribute, and for now I have worked around the issue by making the MemberModuleTestController provide an absolute Link function return.
As far as I can see there's a problem with the thirdparty SimpleURL->asString method which mangles the URL slightly.
Thanks to @dhensby who worked with me in the role of "rubber duck".
Yep, it looks like the simpleform tester assumes that relative links are absolute so parses them incorrectly and returns them with a leading "http://".
So, it sees a form with action "controller/Form" and returns "http://controller/Form" as the URL.