Skip to content

Commit

Permalink
Ensure compatibility with PHPUnit 6.x
Browse files Browse the repository at this point in the history
  • Loading branch information
glye committed Jul 24, 2017
1 parent 0deb748 commit 600b850
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion features/Context/ContentType.php
Expand Up @@ -14,7 +14,7 @@
use eZ\Publish\API\Repository\Values\ContentType\ContentTypeCreateStruct;
use eZ\Publish\API\Repository\Values\ContentType\FieldDefinitionUpdateStruct;
use EzSystems\PlatformBehatBundle\Context\RepositoryContext;
use PHPUnit_Framework_Assert as Assertion;
use PHPUnit\Framework\Assert as Assertion;

final class ContentType extends RawMinkContext implements Context, SnippetAcceptingContext
{
Expand Down
2 changes: 1 addition & 1 deletion features/Context/FieldTypeFormContext.php
Expand Up @@ -11,7 +11,7 @@
use Behat\MinkExtension\Context\RawMinkContext;
use eZ\Publish\API\Repository\Values\ContentType\FieldDefinitionCreateStruct;
use eZ\Publish\API\Repository\Values\ContentType\FieldDefinitionUpdateStruct;
use PHPUnit_Framework_Assert as Assertion;
use PHPUnit\Framework\Assert as Assertion;

final class FieldTypeFormContext extends RawMinkContext implements SnippetAcceptingContext
{
Expand Down
2 changes: 1 addition & 1 deletion features/Context/PagelayoutContext.php
Expand Up @@ -8,7 +8,7 @@
use Behat\Behat\Context\SnippetAcceptingContext;
use Behat\MinkExtension\Context\RawMinkContext;
use eZ\Publish\Core\MVC\ConfigResolverInterface;
use PHPUnit_Framework_Assert as Assertion;
use PHPUnit\Framework\Assert as Assertion;

class PagelayoutContext extends RawMinkContext implements Context, SnippetAcceptingContext
{
Expand Down
2 changes: 1 addition & 1 deletion features/Context/SelectionFieldTypeFormContext.php
Expand Up @@ -7,7 +7,7 @@
use Behat\Behat\Context\SnippetAcceptingContext;
use Behat\Behat\Hook\Scope\BeforeScenarioScope;
use Behat\MinkExtension\Context\RawMinkContext;
use PHPUnit_Framework_Assert as Assertion;
use PHPUnit\Framework\Assert as Assertion;

final class SelectionFieldTypeFormContext extends RawMinkContext implements SnippetAcceptingContext
{
Expand Down
6 changes: 3 additions & 3 deletions features/Context/UserRegistrationContext.php
Expand Up @@ -19,7 +19,7 @@
use eZ\Publish\API\Repository\Values\User\UserGroup;
use eZ\Publish\Core\Repository\Values\User\RoleCreateStruct;
use EzSystems\PlatformBehatBundle\Context\RepositoryContext;
use PHPUnit_Framework_Assert;
use PHPUnit\Framework\Assert as Assertion;
use Symfony\Component\Filesystem\Filesystem;
use Symfony\Component\Yaml\Yaml;

Expand Down Expand Up @@ -300,7 +300,7 @@ public function theUserIsCreatedInThisUserGroup()
$user = $userService->loadUserByLogin($this->registrationUsername);
$userGroups = $userService->loadUserGroupsOfUser($user);

PHPUnit_Framework_Assert::assertEquals(
Assertion::assertEquals(
$this->customUserGroup->id,
$userGroups[0]->id
);
Expand Down Expand Up @@ -347,7 +347,7 @@ public function thePageIsRenderedUsingTheTemplateConfiguredIn($template)
$found = (strpos($html, sprintf('<!-- STOP %s -->', $alternativeTemplate)) !== false);
}

PHPUnit_Framework_Assert::assertTrue(
Assertion::assertTrue(
$found,
"Couldn't find $template " .
(isset($alternativeTemplate) ? "nor $alternativeTemplate " : ' ') .
Expand Down

0 comments on commit 600b850

Please sign in to comment.