php-src/ext/session/tests/021.phpt
John Coggeshall 6ac365896c Modified the experimental new test class to make it easier to port to the
web. Pushed all echo statements through a function that can be
overwritten, changed the way pass/skip/fail is handled (separate function)
that of course can also be overwritten. To begin testing of a web-based
test script also created a webHarness class which will output HTML. To
use, just $a = new webHarness(); instead of $a = new testHarness(); A few
modifications still must be made to remove the CLI reliance completely.

Also modified a test script description.
2002-11-01 00:22:02 +00:00

61 lines
1.1 KiB
PHP

--TEST--
rewriter handles form and fieldset tags correctly
--SKIPIF--
<?php include('skipif.inc'); ?>
--INI--
session.use_cookies=0
session.cache_limiter=
session.use_trans_sid=1
url_rewriter.tags="a=href,area=href,frame=src,input=src,form=,fieldset="
session.name=PHPSESSID
--FILE--
<?php
error_reporting(E_ALL);
session_id("abtest");
session_start();
?>
<form>
<fieldset>
<?php
ob_flush();
ini_set("url_rewriter.tags", "a=href,area=href,frame=src,input=src,form=");
?>
<form>
<fieldset>
<?php
ob_flush();
ini_set("url_rewriter.tags", "a=href,area=href,frame=src,input=src,form=fakeentry");
?>
<form>
<fieldset>
<?php
ob_flush();
ini_set("url_rewriter.tags", "a=href,fieldset=,area=href,frame=src,input=src");
?>
<form>
<fieldset>
<?php
session_destroy();
?>
--EXPECT--
<form><input type="hidden" name="PHPSESSID" value="abtest" />
<fieldset><input type="hidden" name="PHPSESSID" value="abtest" />
<form><input type="hidden" name="PHPSESSID" value="abtest" />
<fieldset>
<form><input type="hidden" name="PHPSESSID" value="abtest" />
<fieldset>
<form>
<fieldset><input type="hidden" name="PHPSESSID" value="abtest" />