Skip to content

Commit 5945697

Browse files
committed
Test http_response_code function
1 parent cf5f26b commit 5945697

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
--TEST--
2+
Test http_response_code basic functionality
3+
--CREDITS--
4+
Gabriel Caruso (carusogabriel@php.net)
5+
--FILE--
6+
<?php
7+
var_dump(
8+
// Get the current default response code
9+
http_response_code(),
10+
// Set a response code
11+
http_response_code(201),
12+
// Get the new response code
13+
http_response_code()
14+
);
15+
?>
16+
--EXPECT--
17+
bool(false)
18+
bool(true)
19+
int(201)

0 commit comments

Comments
 (0)