Skip to content
This repository has been archived by the owner on Mar 9, 2022. It is now read-only.

List of commands and methods

Greg edited this page Oct 16, 2017 · 2 revisions

Class: \Codeception\Extension\SecureShell

Visibility Function
public closeConnection() : true
Close current SSH connection
public dontSeeInRemoteOutput(string $text) : void
Verify that the last remote command output does not contain a specific text
public dontSeeRemoteDir(string $dirname) : void
Verify that a remote folder does not exist in the current remote path
public dontSeeRemoteFile(string $filename) : void
Verify that a file does not exist in the current remote folder
public getConnection() : resource/null Return current SSH connection
Get current SSH connection
public grabRemoteDir(string $dirname) : string[] Array of file names and folder names
Get the remode folder content
public grabRemoteFile(string $filename) : $string File content
Get the content of a remote file over SFTP
public openConnection(string $host, int $port=22, int $auth=1, mixed $args) : resource/null Returns the SSH connection
Open an SSH connection to the host
public runRemoteCommand(string $command) : string[] Return command output 'STDOUT' and 'STDERR'
Run a command on the remote host and return the output
public seeInRemoteOutput(string $text) : void
Verify that the last remote command output contains a specific text
public seeRemoteDir(string $dirname) : void
Verify that a remote folder exists in the current remote path
public seeRemoteFile(string $filename) : void
Verify that a file exists in the current remote folder
protected __authenticate(resource $connection, int $method, mixed $args) : void
Run SSH authentication based on the selected method
protected __checkFingerprint(resource $connection) : string Server public key fingerprint
Check if the SSH server public key fingerprint is valid

This class extends \Codeception\Module

Clone this wiki locally