Annotation of embedaddon/php/ext/session/tests/session_encode_variation3.phpt, revision 1.1
1.1 ! misho 1: --TEST--
! 2: Test session_encode() function : variation
! 3: --SKIPIF--
! 4: <?php include('skipif.inc'); ?>
! 5: --FILE--
! 6: <?php
! 7:
! 8: ob_start();
! 9:
! 10: /*
! 11: * Prototype : string session_encode(void)
! 12: * Description : Encodes the current session data as a string
! 13: * Source code : ext/session/session.c
! 14: */
! 15:
! 16: echo "*** Testing session_encode() : variation ***\n";
! 17:
! 18: var_dump(session_start());
! 19:
! 20: $array = array(1,2,3);
! 21: $_SESSION["foo"] = &$array;
! 22: var_dump(session_encode());
! 23: var_dump(session_destroy());
! 24:
! 25: echo "Done";
! 26: ob_end_flush();
! 27: ?>
! 28: --EXPECTF--
! 29: *** Testing session_encode() : variation ***
! 30: bool(true)
! 31: string(34) "foo|a:3:{i:0;i:1;i:1;i:2;i:2;i:3;}"
! 32: bool(true)
! 33: Done
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>