ftp_constructor.phpt 316 B

123456789101112131415
  1. --TEST--
  2. Attempt to instantiate an FTP\Connection directly
  3. --EXTENSIONS--
  4. ftp
  5. pcntl
  6. --FILE--
  7. <?php
  8. try {
  9. new FTP\Connection();
  10. } catch (Error $ex) {
  11. echo "Exception: ", $ex->getMessage(), "\n";
  12. }
  13. --EXPECT--
  14. Exception: Cannot directly construct FTP\Connection, use ftp_connect() or ftp_ssl_connect() instead