protected function SimpleLdapSSOTestCase::getSSOCookieData in Simple LDAP 7.2
Same name and namespace in other branches
- 7 simple_ldap_sso/simple_ldap_sso.test \SimpleLdapSSOTestCase::getSSOCookieData()
Get the SSO cookie data from the current SSO cookie.
Return value
array The data array.
2 calls to SimpleLdapSSOTestCase::getSSOCookieData()
- SimpleLdapSSOTestCase::prepareSSO in simple_ldap_sso/
simple_ldap_sso.test - Mimick an SSO login.
- SimpleLdapSSOTestCase::testSimpleLdapSSO in simple_ldap_sso/
simple_ldap_sso.test - Test Simple LDAP SSO.
File
- simple_ldap_sso/
simple_ldap_sso.test, line 224 - Simple LDAP SSO module tests.
Class
- SimpleLdapSSOTestCase
- @file Simple LDAP SSO module tests.
Code
protected function getSSOCookieData() {
$this
->assertTrue(isset($this->cookies[SIMPLE_LDAP_SSO_COOKIE]['value']), 'SSO Cookie is set.');
// Verify that cookie is readable.
$cookie_val = urldecode($this->cookies[SIMPLE_LDAP_SSO_COOKIE]['value']);
$this
->verbose($cookie_val);
drupal_static_reset('simple_ldap_sso_get_cookie_data');
$data = simple_ldap_sso_get_cookie_data($cookie_val);
$this
->assertTrue(isset($data['name']), t('SSO Cookie can be decrypted.'));
return $data;
}