We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using Vue for the form submission.
Also left the same comment in a topic that was already closed #39
Cant seem to make the test work with Dusk, though the Feature Test works fine. Dont think the mock is working in Dusk...
If i log the response from the rule, it spits this:
`{"Arcanedev\\NoCaptcha\\Utilities\\ResponseV2":{"success":false,"hostname":null,"challenge_ts":null,"apk_package_name":null,"error-codes":["invalid-input-response"]}}`
So, the rule response comes as false.
Code:
protected function ignoreCaptcha(string $name = 'g-recaptcha-response'): void { NoCaptchaFacade::shouldReceive('display') ->andReturn('<input type="textarea" value="anything, really" name="' . $name . '">'); NoCaptchaFacade::shouldReceive('script') ->andReturn('<script src="captcha.js"></script>'); NoCaptchaFacade::shouldReceive('verify') ->andReturn(NoCaptchaFacade::getFacadeRoot()); NoCaptchaFacade::shouldReceive('isSuccess') ->andReturn(true); } /** @test */ public function it_submits_contact_form() { $this->ignoreCaptcha(); $this->browse(function (Browser $browser) { $browser->visitRoute('contact') ->type('name', $this->faker->name) ->type('email', $this->faker->safeEmail) ->type('message', $this->faker->paragraphs(3, true)) ->fillHidden('g-recaptcha-response', '1') ->pressAndWaitFor('Submit', 3) ->assertSee('Message sent!'); }); }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Using Vue for the form submission.
Also left the same comment in a topic that was already closed #39
Cant seem to make the test work with Dusk, though the Feature Test works fine.
Dont think the mock is working in Dusk...
If i log the response from the rule, it spits this:
So, the rule response comes as false.
Code:
The text was updated successfully, but these errors were encountered: