/**
* Handle a "given" step.
*
* @param array &$world Joined "world" of variables.
* @param string $action The description of the step.
* @param array $arguments Additional arguments to the step.
*
* @return mixed The outcome of the step.
*/
public function runGiven(&$world, $action, $arguments)
{
switch ($action) {
case 'an empty Kolab storage':
$world['storage'] = $this->prepareEmptyKolabStorage();
break;
case 'a Kolab setup':
$result = $this->prepareKolabSetup();
$world['server'] =& $result['server'];
$world['storage'] =& $result['storage'];
$world['auth'] =& $result['auth'];
break;
case 'a populated Kolab setup':
$result = $this->prepareBasicSetup();
$world['server'] =& $result['server'];
$world['storage'] =& $result['storage'];
$world['auth'] =& $result['auth'];
break;
default:
return parent::runGiven($world, $action, $arguments);
}
}