You are here

function user_session_test_anon_session in Drupal 7

Page callback.

Creates an anonymous user session.

2 string references to 'user_session_test_anon_session'
UserLoginTestCase::testLoginWithAnonSession in modules/user/user.test
Test logging in when an anon session already exists.
user_session_test_menu in modules/user/tests/user_session_test.module
Implements hook_menu().

File

modules/user/tests/user_session_test.module, line 25
Dummy module implementing a page callback to create an anon session.

Code

function user_session_test_anon_session() {
  $data = 'This dummy data will be stored in a user session.';
  $_SESSION[__FUNCTION__] = $data;
  return $data;
}