Annotation of embedaddon/php/ext/standard/tests/network/getmxrr.phpt, revision 1.1.1.2

1.1       misho       1: --TEST--
                      2: getmxrr() test
                      3: --SKIPIF--
                      4: <?php
                      5: if (getenv("SKIP_SLOW_TESTS")) die("skip slow test");
1.1.1.2 ! misho       6: if (getenv("SKIP_ONLINE_TESTS")) die("skip test requiring internet connection");
1.1       misho       7: if (substr(PHP_OS, 0, 3) == 'WIN') {
                      8:     die('skip: no Windows support');
                      9: }
                     10: ?>
                     11: --FILE--
                     12: <?php
                     13: $domains = array( 'mx1.tests.php.net', 'mx2.tests.php.net' );
                     14: foreach ( $domains as $domain )
                     15: {
                     16:     if ( getmxrr( $domain, $hosts, $weights ) )
                     17:     {
                     18:         echo "Hosts: " . count( $hosts ) . ", weights: " . count( $weights ) . "\n";
                     19:     }
                     20: }
                     21: ?>
                     22: --EXPECT--
                     23: Hosts: 1, weights: 1
                     24: Hosts: 2, weights: 2

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