protected function DrupalWebTestCase::drupalGetToken

7.x drupal_web_test_case.php protected DrupalWebTestCase::drupalGetToken($value = '')

Generate a token for the currently logged in user.

File

drupal-7.x/modules/simpletest/drupal_web_test_case.php, line 1262

Class

DrupalWebTestCase
Test case for typical Drupal tests.

Code

protected function drupalGetToken($value = '') {
  $private_key = drupal_get_private_key();
  return drupal_hmac_base64($value, $this->session_id . $private_key);
}