| Nuno Lopes 2006-09-14, 6:57 pm |
| nlopess Thu Sep 14 19:24:49 2006 UTC
Modified files:
/qaweb write-test.php
Log:
start updating this: add new sections of phpt files
document new %xx matchers in EXPECTF mode. more to come.. tomorrow
http://cvs.php.net/viewvc.cgi/qaweb...0&diff_format=u
Index: qaweb/write-test.php
diff -u qaweb/write-test.php:1.9 qaweb/write-test.php:1.10
--- qaweb/write-test.php:1.9 Thu Sep 14 18:41:01 2006
+++ qaweb/write-test.php Thu Sep 14 19:24:49 2006
@@ -3,7 +3,7 @@
$TITLE = "Writing Tests [PHP-QAT: Quality Assurance Team]";
$SITE_UPDATE = date("D M d H:i:s Y T", filectime(__FILE__));
-/* $Id: write-test.php,v 1.9 2006/09/14 18:41:01 nlopess Exp $ */
+/* $Id: write-test.php,v 1.10 2006/09/14 19:24:49 nlopess Exp $ */
common_header();
?>
@@ -120,9 +120,17 @@
<dt>--POST--</dt>
<dd>POST variables to be passed to the test script. (optional)</dd>
+<dt>--POST_RAW--</dt>
+<dd>RAW POST data to be passed to the test script. This differs from the section
+above because it doesn't set the Content-Type, which can be set manually in
+this section. (optional)</dd>
+
<dt>--GET--</dt>
<dd>GET variables to be passed to the test script. (optional)</dd>
+<dt>--STDIN--</dt>
+<dd>data to be fed to the test script's standard input. (optional)</dd>
+
<dt>--INI--</dt>
<dd>to be used if you need a specific php.ini setting for the test.
Each line contains an ini setting e.g. foo=bar. (optional)</dd>
@@ -179,8 +187,9 @@
changed and sometimes the machine used to execute the code has influence
on the result of shuffle. But it always returns a three character string
detectable by %s. Other scan-able forms are %i for integers, %d for numbers
-only, %f for floating point values, %c for single characters and %x for
-hexadecimal values.</p>
+only, %f for floating point values, %c for single characters, %x for
+hexadecimal values, %w for any number of whitespace characters and %e for
+DIRECTORY_SEPARATOR ('' or '/').</p>
<i>/ext/standard/tests/strings/str_shuffle.phpt</i>
<pre>
--TEST--
@@ -260,7 +269,7 @@
<p>
<b>Note:</b> no file used by any test should have one of the following extensions:
-".php", ".log", ".exp", ".out" or ".diff". When you use an include file for the
+".php", ".log", ".mem", ".exp", ".out" or ".diff". When you use an include file for the
SKIPIF section it should be named "skipif.inc" and an include file used in the
FILE section of many tests should be named "test.inc".</p>
@@ -305,7 +314,7 @@
it disturbs having a long --EXPECT-- block, so that you don't see the actual
output as it scrolls away overwritten by the blocks following the actual file
block. The workaround is to use terminate the --FILE-- section with the two
-lines "===DONE===" and "<?php echo "<\?php exit(0); ?\>"; ?>".
+lines "===DONE===" and "<?php exit(0); ?>.
When doing so run-tests.php does not execute the line containing the exit call
as that would suppress leak messages. Actually run-tests.php ignores any part
after a line consisting only of "===DONE===".</p>
|