You are here

private function CaptchaAdminTestCase::getCaptchaPointSettingFromDatabase in CAPTCHA 7

Same name and namespace in other branches
  1. 6.2 captcha.test \CaptchaAdminTestCase::getCaptchaPointSettingFromDatabase()

Helper function to get the CAPTCHA point setting straight from the database.

Parameters

string $form_id:

Return value

stdClass object

2 calls to CaptchaAdminTestCase::getCaptchaPointSettingFromDatabase()
CaptchaAdminTestCase::testCaptchaPointAdministration in ./captcha.test
Method for testing the CAPTCHA point administration
CaptchaAdminTestCase::testCaptchaPointAdministrationByNonAdmin in ./captcha.test
Method for testing the CAPTCHA point administration

File

./captcha.test, line 645
Tests for CAPTCHA module.

Class

CaptchaAdminTestCase

Code

private function getCaptchaPointSettingFromDatabase($form_id) {
  $result = db_query("SELECT * FROM {captcha_points} WHERE form_id = :form_id", array(
    ':form_id' => $form_id,
  ))
    ->fetchObject();
  return $result;
}