protected function CaptchaBaseWebTestCase::getCommentFormValues in CAPTCHA 7
Same name and namespace in other branches
- 6.2 captcha.test \CaptchaBaseWebTestCase::getCommentFormValues()
Helper function to generate a form values array for comment forms
5 calls to CaptchaBaseWebTestCase::getCommentFormValues()
- CaptchaAdminTestCase::testUntrustedUserPosting in ./
captcha.test - CaptchaSessionReuseAttackTestCase::testCaptchaSessionReuseAttackDetectionOnCommentPreview in ./
captcha.test - CaptchaSessionReuseAttackTestCase::testMultipleCaptchaProtectedFormsOnOnePage in ./
captcha.test - CaptchaTestCase::assertCommentPosting in ./
captcha.test - Assert function for testing if comment posting works as it should.
- CaptchaTestCase::testCaptchaDescriptionAfterCommentPreview in ./
captcha.test - Test if the CAPTCHA description is only shown if there are challenge widgets to show. For example, when a comment is previewed with correct CAPTCHA answer, a challenge is generated and added to the form but removed in the pre_render phase. The CAPTCHA…
File
- ./
captcha.test, line 142 - Tests for CAPTCHA module.
Class
- CaptchaBaseWebTestCase
- Base class for CAPTCHA tests.
Code
protected function getCommentFormValues() {
$edit = array(
'subject' => 'comment_subject ' . $this
->randomName(32),
'comment_body[' . LANGUAGE_NONE . '][0][value]' => 'comment_body ' . $this
->randomName(256),
);
return $edit;
}