mirror of
https://github.com/silverstripe/silverstripe-reports
synced 2024-10-22 11:05:53 +02:00
Convert behat PHP to SS coding conventions
This commit is contained in:
parent
c3b7afbdb1
commit
34c8fb22cb
@ -20,16 +20,15 @@ require_once 'PHPUnit/Framework/Assert/Functions.php';
|
||||
* Context automatically loaded by Behat.
|
||||
* Uses subcontexts to extend functionality.
|
||||
*/
|
||||
class FeatureContext extends \SilverStripe\Framework\Test\Behaviour\FeatureContext
|
||||
{
|
||||
class FeatureContext extends \SilverStripe\Framework\Test\Behaviour\FeatureContext {
|
||||
|
||||
/**
|
||||
* Initializes context.
|
||||
* Every scenario gets it's own context object.
|
||||
*
|
||||
* @param array $parameters context parameters (set them up through behat.yml)
|
||||
*/
|
||||
public function __construct(array $parameters)
|
||||
{
|
||||
public function __construct(array $parameters) {
|
||||
parent::__construct($parameters);
|
||||
|
||||
// Override existing fixture context with more specific one
|
||||
|
@ -19,8 +19,7 @@ require_once 'PHPUnit/Framework/Assert/Functions.php';
|
||||
/**
|
||||
* Context used to create fixtures in the SilverStripe ORM.
|
||||
*/
|
||||
class FixtureContext extends \SilverStripe\BehatExtension\Context\FixtureContext
|
||||
{
|
||||
class FixtureContext extends \SilverStripe\BehatExtension\Context\FixtureContext {
|
||||
|
||||
/**
|
||||
* Find or create a redirector page and link to another existing page.
|
||||
@ -28,8 +27,7 @@ class FixtureContext extends \SilverStripe\BehatExtension\Context\FixtureContext
|
||||
*
|
||||
* @Given /^(?:(an|a|the) )"(?<type>[^"]+)" "(?<id>[^"]+)" (:?which )?redirects to (?:(an|a|the) )"(?<targetType>[^"]+)" "(?<targetId>[^"]+)"$/
|
||||
*/
|
||||
public function stepCreateRedirectorPage($type, $id, $targetType, $targetId)
|
||||
{
|
||||
public function stepCreateRedirectorPage($type, $id, $targetType, $targetId) {
|
||||
$class = 'RedirectorPage';
|
||||
$targetClass = $this->convertTypeToClass($targetType);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user