- extend & fixup test suite
[m6w6/ext-http] / tests / redirect_013.phpt
diff --git a/tests/redirect_013.phpt b/tests/redirect_013.phpt
new file mode 100644 (file)
index 0000000..8ef8a6b
--- /dev/null
@@ -0,0 +1,24 @@
+--TEST--
+http_redirect() permanent
+--SKIPIF--
+<?php 
+include 'skip.inc';
+checkcgi();
+checkmin(5.1);
+?>
+--ENV--
+HTTP_HOST=localhost
+--FILE--
+<?php
+include 'log.inc';
+log_prepare(_REDIR_LOG);
+http_redirect('redirect', null, false, HTTP_REDIRECT_PERM);
+?>
+--EXPECTF--
+Status: 301
+X-Powered-By: PHP/%s
+Location: http://localhost/redirect
+Content-type: %s
+
+Redirecting to <a href="http://localhost/redirect">http://localhost/redirect</a>.
+