mirror of
https://github.com/phpseclib/phpseclib.git
synced 2024-11-11 16:15:52 +00:00
Tests/SSH2: add unit test for #1167
This commit is contained in:
parent
a3325d102e
commit
ed3846a7a2
@ -146,5 +146,25 @@ class Functional_Net_SSH2Test extends PhpseclibFunctionalTestCase
|
|||||||
$ssh->exec('ls -latr');
|
$ssh->exec('ls -latr');
|
||||||
$ssh->disablePTY();
|
$ssh->disablePTY();
|
||||||
$ssh->exec('pwd');
|
$ssh->exec('pwd');
|
||||||
|
|
||||||
|
return $ssh;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @depends testDisablePTY
|
||||||
|
* @group github1167
|
||||||
|
*/
|
||||||
|
public function testChannelDataAfterOpen($ssh)
|
||||||
|
{
|
||||||
|
$ssh->write("ping 127.0.0.1\n");
|
||||||
|
|
||||||
|
$ssh->enablePTY();
|
||||||
|
$ssh->exec('bash');
|
||||||
|
|
||||||
|
$ssh->write("ls -latr\n");
|
||||||
|
|
||||||
|
$ssh->setTimeout(1);
|
||||||
|
|
||||||
|
$ssh->read();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user