Annotation of embedaddon/php/ext/imap/tests/imap_headerinfo_error.phpt, revision 1.1

1.1     ! misho       1: --TEST--
        !             2: imap_headerinfo() incorrect parameter count
        !             3: --CREDITS--
        !             4: Olivier Doucet
        !             5: --SKIPIF--
        !             6: <?php
        !             7: require_once(dirname(__FILE__).'/skipif.inc');
        !             8: ?>
        !             9: --FILE--
        !            10: <?php
        !            11: echo "Checking with no parameters\n";
        !            12: imap_headerinfo();
        !            13: 
        !            14: echo  "Checking with incorrect parameter type\n";
        !            15: imap_headerinfo('');
        !            16: imap_headerinfo(false);
        !            17: 
        !            18: require_once(dirname(__FILE__).'/imap_include.inc');
        !            19: $stream_id = imap_open($default_mailbox, $username, $password) or 
        !            20:        die("Cannot connect to mailbox $default_mailbox: " . imap_last_error());
        !            21:        
        !            22: imap_headerinfo($stream_id);
        !            23: 
        !            24: imap_close($stream_id);
        !            25: ?>
        !            26: --EXPECTF--
        !            27: Checking with no parameters
        !            28: 
        !            29: Warning: imap_headerinfo() expects at least 2 parameters, 0 given in %s on line %d
        !            30: Checking with incorrect parameter type
        !            31: 
        !            32: Warning: imap_headerinfo() expects at least 2 parameters, 1 given in %s on line %d
        !            33: 
        !            34: Warning: imap_headerinfo() expects at least 2 parameters, 1 given in %s on line %d
        !            35: 
        !            36: Warning: imap_headerinfo() expects at least 2 parameters, 1 given in %s on line %d

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