You are here

public function ReCaptchaServerStatusTestCase::testServerStatusCache in reCAPTCHA 7

File

tests/recaptcha_server_status.test, line 40
Contains ReCaptcha.

Class

ReCaptchaServerStatusTestCase
Test cases for ReCaptcha module UI.

Code

public function testServerStatusCache() {

  // No cache before status check.
  $status_cache = cache_get('recaptcha_server_status');
  $this
    ->assertFalse($status_cache);

  // Call status check to set Cache.
  _recaptcha_server_is_up();
  $status_cache = cache_get('recaptcha_server_status');
  $this
    ->assertNotNull($status_cache);
}