diff options
author | Thies C. Arntzen <thies@php.net> | 2001-07-09 09:08:14 +0000 |
---|---|---|
committer | Thies C. Arntzen <thies@php.net> | 2001-07-09 09:08:14 +0000 |
commit | e7b01fc53c717077ff209baa24760edd40525951 (patch) | |
tree | 4cceef19ebe1c15af7c9eb1aa4df02fc543931a7 | |
parent | 08546ef0e87306da16c99c6e5ef9ba68a92a7625 (diff) | |
download | php-git-e7b01fc53c717077ff209baa24760edd40525951.tar.gz |
added test for assert
-rw-r--r-- | ext/standard/tests/assert/assert.phpt | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/ext/standard/tests/assert/assert.phpt b/ext/standard/tests/assert/assert.phpt new file mode 100644 index 0000000000..92c40eef69 --- /dev/null +++ b/ext/standard/tests/assert/assert.phpt @@ -0,0 +1,21 @@ +--TEST-- +assert() +--POST-- +--GET-- +--FILE-- +<? +assert_options(ASSERT_ACTIVE,1); +assert_options(ASSERT_CALLBACK,"a"); +assert_options(ASSERT_QUIET_EVAL,1); +assert_options(ASSERT_WARNING,0); +assert_options(ASSERT_BAIL,1); + +function a($file,$line,$myev) +{ echo "assertion failed $line,\"$myev\"\n"; +} + +$a = 0; +assert('$a != 0'); +?> +--EXPECT-- +assertion failed 13,"$a != 0" |