mirror of
https://github.com/owncloud/ocis
synced 2026-04-25 17:25:21 +02:00
test: get necessary contexts properly
This commit is contained in:
@@ -25,10 +25,11 @@ use Behat\Behat\Hook\Scope\BeforeScenarioScope;
|
||||
use Behat\Gherkin\Node\TableNode;
|
||||
use GuzzleHttp\Exception\GuzzleException;
|
||||
use PHPUnit\Framework\Assert;
|
||||
use Psr\Http\Message\ResponseInterface;
|
||||
use TestHelpers\HttpRequestHelper;
|
||||
use TestHelpers\WebDavHelper;
|
||||
use Psr\Http\Message\ResponseInterface;
|
||||
use TestHelpers\OcisHelper;
|
||||
use TestHelpers\BehatHelper;
|
||||
|
||||
require_once 'bootstrap.php';
|
||||
|
||||
@@ -991,10 +992,8 @@ class WebDavLockingContext implements Context {
|
||||
// Get the environment
|
||||
$environment = $scope->getEnvironment();
|
||||
// Get all the contexts you need in this context
|
||||
$this->featureContext = $environment->getContext('FeatureContext');
|
||||
$this->publicWebDavContext = $environment->getContext('PublicWebDavContext');
|
||||
if (!OcisHelper::isTestingOnReva()) {
|
||||
$this->spacesContext = $environment->getContext('SpacesContext');
|
||||
}
|
||||
$this->featureContext = BehatHelper::getContext($scope, $environment, 'FeatureContext');
|
||||
$this->publicWebDavContext = BehatHelper::getContext($scope, $environment, 'PublicWebDavContext');
|
||||
$this->spacesContext = BehatHelper::getContext($scope, $environment, 'SpacesContext');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user