Annotation of embedaddon/php/ext/standard/tests/assert/assert03.phpt, revision 1.1

1.1     ! misho       1: --TEST--
        !             2: assert() - set callback using ini_set()
        !             3: --INI--
        !             4: assert.active = 1
        !             5: assert.warning = 0
        !             6: assert.callback = 
        !             7: assert.bail = 0
        !             8: assert.quiet_eval = 1
        !             9: --FILE--
        !            10: <?php
        !            11: function a($file,$line,$myev)
        !            12: { 
        !            13:                echo "assertion failed - a - $line,\"$myev\"\n";
        !            14: }
        !            15:  
        !            16: function b($file,$line,$myev)
        !            17: { 
        !            18:                echo "assertion failed - b - $line,\"$myev\"\n";
        !            19: }
        !            20:  
        !            21: assert_options(ASSERT_ACTIVE,1);
        !            22: assert_options(ASSERT_QUIET_EVAL,1);
        !            23: assert_options(ASSERT_WARNING,0);
        !            24:  
        !            25: $a = 0;
        !            26:  
        !            27: assert_options(ASSERT_CALLBACK,"a");
        !            28: assert('$a != 0');
        !            29:  
        !            30:  /* Modify call back using ini_set() */
        !            31: ini_set("assert.callback", "b");
        !            32: assert('$a != 0');
        !            33: 
        !            34: ?>
        !            35: ==DONE==
        !            36: --EXPECTF--
        !            37: assertion failed - a - %d,"$a != 0"
        !            38: assertion failed - b - %d,"$a != 0"
        !            39: ==DONE==

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>