summaryrefslogtreecommitdiff
path: root/tests/output/ob_end_clean_basic_001.phpt
blob: 0b694e36ca74a8af10ce393c76d884a6f03e1bcb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
--TEST--
Test return type and value, as well as basic behaviour, for ob_end_clean()
--FILE--
<?php
/* 
 * proto bool ob_end_clean(void)
 * Function is implemented in main/output.c
*/ 

var_dump(ob_end_clean());

ob_start();
var_dump(ob_end_clean());

ob_start();
echo "Hello";
var_dump(ob_end_clean());

var_dump(ob_end_clean());

?>
--EXPECTF--

Notice: ob_end_clean(): failed to delete buffer. No buffer to delete. in %s on line 7
bool(false)
bool(true)
bool(true)

Notice: ob_end_clean(): failed to delete buffer. No buffer to delete. in %s on line 16
bool(false)