mirror of
https://github.com/danog/tgseclib.git
synced 2024-11-30 04:39:02 +01:00
Tests/SSH2: add unit test for #1009
This commit is contained in:
parent
83514e3991
commit
9bccc01b97
@ -112,6 +112,8 @@ class Functional_Net_SSH2Test extends PhpseclibFunctionalTestCase
|
|||||||
->method('callbackMethod')
|
->method('callbackMethod')
|
||||||
->will($this->returnValue(true));
|
->will($this->returnValue(true));
|
||||||
$ssh->exec('pwd', array($callbackObject, 'callbackMethod'));
|
$ssh->exec('pwd', array($callbackObject, 'callbackMethod'));
|
||||||
|
|
||||||
|
return $ssh;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testGetServerPublicHostKey()
|
public function testGetServerPublicHostKey()
|
||||||
@ -133,4 +135,16 @@ class Functional_Net_SSH2Test extends PhpseclibFunctionalTestCase
|
|||||||
'SSH2 login using an open socket failed.'
|
'SSH2 login using an open socket failed.'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @depends testExecWithMethodCallback
|
||||||
|
* @group github1009
|
||||||
|
*/
|
||||||
|
public function testDisablePTY($ssh)
|
||||||
|
{
|
||||||
|
$ssh->enablePTY();
|
||||||
|
$ssh->exec('ls -latr');
|
||||||
|
$ssh->disablePTY();
|
||||||
|
$ssh->exec('pwd');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user