in reply to Re^4: SSH2 for windows
in thread SSH2 for windows

Hi Rob,

Test, Only ran 11

1..72 ok 1 - use Net::SSH2; ok 2 - new session isa Net::SSH2 ok 3 - error state clear ok 4 - set banner ok 5 - LIBSSH2_* constants ok 6 - libSSH2 version 0.14 > 0.11 ok 7 - list version match ok 8 - API date yyyymmddhhmm ok 9 - banner is SSH-2.0-libssh2_0.14 ok 10 - poll indefinite ok 11 - poll 1/4 second To test the connection capabilities of Net::SSH2, we need a test site +running a secure shell server daemon. Enter 'localhost' to use this host. Select host [ENTER to skip]: localhost Net::SSH2::connect: failed to connect to localhost:22: Unknown error a +t 1 line 5 7 # Looks like you planned 72 tests but only ran 11. # Looks like your test died just after 11.

Replies are listed 'Best First'.
Re^6: SSH2 for windows
by syphilis (Archbishop) on Dec 06, 2006 at 13:42 UTC
    Hi shanthiann,

    Select host [ENTER to skip]: localhost

    What happens if, instead of "localhost", you enter the secure shell server that you're trying to connect to (ie the "$hostname" in your script) ?

    Cheers,
    Rob
      Dear Rob,

      Now it ran upto 22 test, after giving a secure host ip.
      1..72 ok 1 - use Net::SSH2; ok 2 - new session isa Net::SSH2 ok 3 - error state clear ok 4 - set banner ok 5 - LIBSSH2_* constants ok 6 - libSSH2 version 0.14 > 0.11 ok 7 - list version match ok 8 - API date yyyymmddhhmm ok 9 - banner is SSH-2.0-libssh2_0.14 ok 10 - poll indefinite ok 11 - poll 1/4 second To test the connection capabilities of Net::SSH2, we need a test site +running a secure shell server daemon. Enter 'localhost' to use this host. Select host [ENTER to skip]: 10.123.3.9 ok 12 - connect to 10.123.3.9 ok 13 - kex method: diffie-hellman-group-exchange-sha1 ok 14 - hostkey method: ssh-rsa ok 15 - crypt_cs method: aes256-cbc ok 16 - crypt_sc method: aes256-cbc ok 17 - mac_cs method: hmac-sha1 ok 18 - mac_sc method: hmac-sha1 ok 19 - comp_cs method: none ok 20 - comp_sc method: none ok 21 - have MD5 hostkey hash ok 22 - have SHA1 hostkey hash The getpwuid function is unimplemented at 1 line 73, <STDIN> line 1. # Looks like you planned 72 tests but only ran 22. # Looks like your test died just after 22.


      Please advice
        The getpwuid function is unimplemented at 1 line 73, <STDIN> line 1.

        You should submit a bug report to http://rt.cpan.org/Public/Dist/Display.html?Name=Net-SSH2. Test scripts should be portable- the author is probably unaware that his test script is not portable.

        As Anonymous Monk suggested, I think it is worth the effort of hacking the test script with a workaround (if possible) so that the remaining tests can be run.

        Is there anything in the test script's code that helps you with the code you're trying to write ? I've often found that test scripts provide useful examples of how to code correctly.

        Cheers,
        Rob