Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions src/JoomlaBrowser.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,21 @@ public function doFrontEndLogin($user = null, $password = null)
$I->waitForElement(['xpath' => "//input[@value='Log out']"], 10);
}

/**
* Function to Do frontend Logout in Joomla!
*/
public function doFrontendLogout()
{
$I = $this;
$this->debug('I open Joomla Frontend Login Page');
$I->amOnPage('/index.php?option=com_users&view=login');
$this->debug('I click Logout button');
$I->click(['xpath' => "//div[@class='logout']//button[contains(text(), 'Log out')]"]);
$this->debug('I wait to see Login form');
$I->waitForElement(['xpath' => "//div[@class='login']//button[contains(text(), 'Log in')]"], 30);
$I->seeElement(['xpath' => "//div[@class='login']//button[contains(text(), 'Log in')]"]);
}

/**
* Installs Joomla
*/
Expand Down