Skip to content

Commit

Permalink
Fix #60
Browse files Browse the repository at this point in the history
  • Loading branch information
vincentchalamon committed Sep 3, 2020
1 parent 45509c4 commit ee386ae
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 25 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ on:
schedule:
- cron: 0 2 * * 1-5
pull_request:
push:
branches:
- master

jobs:
tests:
Expand All @@ -21,7 +24,7 @@ jobs:
symfony:
- '3.4.*'
- '4.4.*'
- '5.0.*'
- '5.1.*'
dependency:
- '--prefer-stable'
- '--prefer-stable --prefer-lowest'
Expand Down
7 changes: 4 additions & 3 deletions Manager/Bridge/DoctrineManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,17 @@

namespace CoopTilleuls\ForgotPasswordBundle\Manager\Bridge;

use Doctrine\Common\Persistence\ManagerRegistry;

/**
* @author Vincent Chalamon <[email protected]>
*/
final class DoctrineManager implements ManagerInterface
{
private $registry;

public function __construct(ManagerRegistry $registry)
/**
* @var \Doctrine\Common\Persistence\ManagerRegistry|\Doctrine\Persistence\ManagerRegistry
*/
public function __construct($registry)
{
$this->registry = $registry;
}
Expand Down
30 changes: 15 additions & 15 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,12 @@
"require": {
"php": ">=7.2",
"ircmaxell/random-lib": "^1.2",
"symfony/config": "^3.4 || ^4.4 || ^5.0",
"symfony/dependency-injection": "^3.4 || ^4.4 || ^5.0",
"symfony/event-dispatcher": "^3.4 || ^4.4 || ^5.0",
"symfony/http-foundation": "^3.4 || ^4.4 || ^5.0",
"symfony/http-kernel": "^3.4 || ^4.4 || ^5.0",
"symfony/serializer": "^3.4 || ^4.4 || ^5.0"
"symfony/config": "^3.4 || ^4.4 || ^5.1",
"symfony/dependency-injection": "^3.4 || ^4.4 || ^5.1",
"symfony/event-dispatcher": "^3.4 || ^4.4 || ^5.1",
"symfony/http-foundation": "^3.4 || ^4.4 || ^5.1",
"symfony/http-kernel": "^3.4 || ^4.4 || ^5.1",
"symfony/serializer": "^3.4 || ^4.4 || ^5.1"
},
"require-dev": {
"behat/behat": "^3.1",
Expand All @@ -40,16 +40,16 @@
"phpunit/phpunit": "^8.0",
"sebastian/comparator": "^3.0",
"swiftmailer/swiftmailer": "^6.2",
"symfony/asset": "^3.4 || ^4.4 || ^5.0",
"symfony/browser-kit": "^3.4 || ^4.4 || ^5.0",
"symfony/framework-bundle": "^3.4 || ^4.4 || ^5.0",
"symfony/property-access": "^3.4 || ^4.4 || ^5.0",
"symfony/security-bundle": "^3.4 || ^4.4 || ^5.0",
"symfony/stopwatch": "^3.4 || ^4.4 || ^5.0",
"symfony/asset": "^3.4 || ^4.4 || ^5.1",
"symfony/browser-kit": "^3.4 || ^4.4 || ^5.1",
"symfony/framework-bundle": "^3.4 || ^4.4 || ^5.1",
"symfony/property-access": "^3.4 || ^4.4 || ^5.1",
"symfony/security-bundle": "^3.4 || ^4.4 || ^5.1",
"symfony/stopwatch": "^3.4 || ^4.4 || ^5.1",
"symfony/swiftmailer-bundle": "^2.3.11 || ^3.4",
"symfony/templating": "^3.4 || ^4.4 || ^5.0",
"symfony/twig-bundle": "^3.4 || ^4.4 || ^5.0",
"symfony/var-dumper": "^3.4 || ^4.4 || ^5.0",
"symfony/templating": "^3.4 || ^4.4 || ^5.1",
"symfony/twig-bundle": "^3.4 || ^4.4 || ^5.1",
"symfony/var-dumper": "^3.4 || ^4.4 || ^5.1",
"zendframework/zend-code": "^3.4"
},
"suggest": {
Expand Down
12 changes: 6 additions & 6 deletions tests/Manager/Bridge/DoctrineManagerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
namespace Tests\ForgotPasswordBundle\Manager\Bridge;

use CoopTilleuls\ForgotPasswordBundle\Manager\Bridge\DoctrineManager;
use Doctrine\Common\Persistence\ManagerRegistry;
use Doctrine\Common\Persistence\ObjectManager;
use Doctrine\Common\Persistence\ObjectRepository;
use Doctrine\Bundle\DoctrineBundle\Registry;
use Doctrine\ORM\EntityManagerInterface;
use Doctrine\ORM\EntityRepository;
use PHPUnit\Framework\TestCase;

/**
Expand All @@ -33,9 +33,9 @@ final class DoctrineManagerTest extends TestCase

protected function setUp(): void
{
$this->registryMock = $this->prophesize(ManagerRegistry::class);
$this->managerMock = $this->prophesize(ObjectManager::class);
$this->repositoryMock = $this->prophesize(ObjectRepository::class);
$this->registryMock = $this->prophesize(Registry::class);
$this->managerMock = $this->prophesize(EntityManagerInterface::class);
$this->repositoryMock = $this->prophesize(EntityRepository::class);
$this->objectMock = $this->prophesize(\stdClass::class);

$this->doctrineManager = new DoctrineManager($this->registryMock->reveal());
Expand Down

0 comments on commit ee386ae

Please sign in to comment.