1--TEST--
2Test session_regenerate_id() function : variation
3--SKIPIF--
4<?php include('skipif.inc'); ?>
5--FILE--
6<?php
7
8ob_start();
9
10/*
11 * Prototype : bool session_regenerate_id([bool $delete_old_session])
12 * Description : Update the current session id with a newly generated one
13 * Source code : ext/session/session.c
14 */
15
16echo "*** Testing session_regenerate_id() : variation ***\n";
17
18var_dump(session_id());
19var_dump(session_regenerate_id(TRUE));
20var_dump(session_id());
21var_dump(session_start());
22var_dump(session_regenerate_id(TRUE));
23var_dump(session_id());
24var_dump(session_destroy());
25var_dump(session_regenerate_id(TRUE));
26var_dump(session_id());
27
28echo "Done";
29ob_end_flush();
30?>
31--EXPECTF--
32*** Testing session_regenerate_id() : variation ***
33string(0) ""
34bool(false)
35string(0) ""
36bool(true)
37bool(true)
38string(%d) "%s"
39bool(true)
40bool(false)
41string(0) ""
42Done
43
44