Annotation of embedaddon/php/ext/standard/tests/general_functions/bug31190.phpt, revision 1.1.1.1

1.1       misho       1: --TEST--
                      2: Bug #31190 (exception in call_user_func_array())
                      3: --FILE--
                      4: <?php
                      5: 
                      6: class test {
                      7:      function throwException() { throw new Exception("Hello World!\n"); 
                      8: } }
                      9: 
                     10: $array = array(new test(), 'throwException');
                     11: try {
                     12:      call_user_func($array, 1, 2);
                     13: } catch (Exception $e) {
                     14:      echo $e->getMessage();
                     15: }
                     16: 
                     17: try {
                     18:      call_user_func_array($array, array(1, 2));
                     19: } catch (Exception $e) {
                     20:      echo $e->getMessage();
                     21: }
                     22: ?>
                     23: --EXPECT--
                     24: Hello World!
                     25: Hello World!
                     26: 

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