Prose\ExpectsHost::processIsNotRunning PHP Method

processIsNotRunning() public method

public processIsNotRunning ( $processName )
    public function processIsNotRunning($processName)
    {
        // what are we doing?
        $log = usingLog()->startAction("make sure process '{$processName}' is not running on host '{$this->args[0]}'");
        // make sure we have valid host details
        $hostDetails = $this->getHostDetails();
        // is the process running?
        $isRunning = fromHost($hostDetails->hostId)->getProcessIsRunning($processName);
        if ($isRunning) {
            throw new E5xx_ExpectFailed(__METHOD__, "process '{$processName}' not running", "process '{$processName}' is running");
        }
        // all done
        $log->endAction();
    }