public function testIsUserLoggedIn() { $this->assertFalse(Authentication::isUserLoggedIn()); $this->setSuccess(); $this->setUserAuthInfo(); Authentication::login(); $this->assertTrue(Authentication::isUserLoggedIn()); }
public function startDdockSession($documentPath, $storePath) { if (!Authentication::isUserLoggedIn()) { Authentication::login(); } try { $contents = file_get_contents($documentPath); $contents = $this->prepareDdocDataFile($contents, $storePath); $result = $this->soap->startSession("", $contents, true)['Sesscode']; if (is_int($result)) { return $result; } else { throw new SigningException($result['Status']); } } catch (\SoapFault $e) { throw $this->soapError($e); } }