1--TEST--
2Test session_gc() function : basic functionality
3--SKIPIF--
4<?php include('skipif.inc'); ?>
5--FILE--
6<?php
7
8ob_start();
9
10/*
11 * Prototype : int session_gc(void)
12 * Description : Perform GC
13 * Source code : ext/session/session.c
14 */
15
16echo "*** Testing session_gc() : basic functionality ***\n";
17
18var_dump(session_gc());
19
20var_dump(session_start());
21var_dump(session_gc(), session_gc() >= -1);
22var_dump(session_destroy());
23var_dump(session_id());
24
25echo "Done";
26ob_end_flush();
27?>
28--EXPECTF--
29*** Testing session_gc() : basic functionality ***
30
31Warning: session_gc(): Session is not active in %s on line %d
32bool(false)
33bool(true)
34int(%d)
35bool(true)
36bool(true)
37string(0) ""
38Done
39