script:
- ant prepare-$DB
- - SYMFONY_DEPRECATIONS_HELPER=weak bin/phpunit --exclude-group command-doctrine -v
+ - SYMFONY_DEPRECATIONS_HELPER=weak bin/phpunit -v
# after_script:
# - |
auto_generate_proxy_classes: "%kernel.debug%"
entity_managers:
default:
- naming_strategy: wallabag_core.doctrine.prefixed_naming_strategy
auto_mapping: true
# Swiftmailer Configuration
"php": ">=5.3.3",
"symfony/symfony": "~2.7.0",
"doctrine/orm": "~2.3",
- "doctrine/doctrine-bundle": "~1.2",
+ "doctrine/doctrine-bundle": "1.5.2",
"twig/extensions": "~1.0",
"symfony/assetic-bundle": "~2.3",
"symfony/swiftmailer-bundle": "~2.3",
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
"This file is @generated automatically"
],
- "hash": "01e7829e7ff2b39b288871661bb05e9a",
- "content-hash": "76830bc9c2cd6f600613c9eea7c0f1b1",
+ "hash": "6bd09434f83c7e6b5e1c75fddbd7608b",
+ "content-hash": "d07d54c4cc6f4f4947c652bd659af02e",
"packages": [
{
"name": "doctrine/annotations",
},
{
"name": "doctrine/doctrine-bundle",
- "version": "1.6.0",
+ "version": "v1.5.2",
"source": {
"type": "git",
"url": "https://github.com/doctrine/DoctrineBundle.git",
- "reference": "a5b3ba908ba68f3e14e42762a7b940fde65ed7da"
+ "reference": "d63be7eb9a95d46720f7d6badac4e5bc2bcff2e3"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/doctrine/DoctrineBundle/zipball/a5b3ba908ba68f3e14e42762a7b940fde65ed7da",
- "reference": "a5b3ba908ba68f3e14e42762a7b940fde65ed7da",
+ "url": "https://api.github.com/repos/doctrine/DoctrineBundle/zipball/d63be7eb9a95d46720f7d6badac4e5bc2bcff2e3",
+ "reference": "d63be7eb9a95d46720f7d6badac4e5bc2bcff2e3",
"shasum": ""
},
"require": {
"orm",
"persistence"
],
- "time": "2015-11-04 21:33:02"
+ "time": "2015-08-31 14:47:06"
},
{
"name": "doctrine/doctrine-cache-bundle",
},
{
"name": "sensiolabs/security-checker",
- "version": "v3.0.1",
+ "version": "v3.0.2",
"source": {
"type": "git",
"url": "https://github.com/sensiolabs/security-checker.git",
- "reference": "7735fd97ff7303d9df776b8dbc970f949399abc9"
+ "reference": "21696b0daa731064c23cfb694c60a2584a7b6e93"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sensiolabs/security-checker/zipball/7735fd97ff7303d9df776b8dbc970f949399abc9",
- "reference": "7735fd97ff7303d9df776b8dbc970f949399abc9",
+ "url": "https://api.github.com/repos/sensiolabs/security-checker/zipball/21696b0daa731064c23cfb694c60a2584a7b6e93",
+ "reference": "21696b0daa731064c23cfb694c60a2584a7b6e93",
"shasum": ""
},
"require": {
- "symfony/console": "~2.0"
+ "symfony/console": "~2.0|~3.0"
},
"bin": [
"security-checker"
}
],
"description": "A security checker for your composer.lock",
- "time": "2015-08-11 12:11:25"
+ "time": "2015-11-07 08:07:40"
},
{
"name": "simplepie/simplepie",
namespace Wallabag\ApiBundle\Tests\Controller;
-use Wallabag\ApiBundle\Tests\AbstractControllerTest;
+use Wallabag\ApiBundle\Tests\WallabagApiTestCase;
-class WallabagRestControllerTest extends AbstractControllerTest
+class WallabagRestControllerTest extends WallabagApiTestCase
{
protected static $salt;
use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
use Symfony\Component\BrowserKit\Cookie;
-abstract class AbstractControllerTest extends WebTestCase
+abstract class WallabagApiTestCase extends WebTestCase
{
/**
* @var Client
if (!$fulfilled) {
throw new \RuntimeException('Some system requirements are not fulfilled. Please check output messages and fix them.');
- } else {
- $this->defaultOutput->writeln('<info>Success! Your system can run Wallabag properly.</info>');
}
+ $this->defaultOutput->writeln('<info>Success! Your system can run Wallabag properly.</info>');
+
$this->defaultOutput->writeln('');
return $this;
// user want to reset everything? Don't care about what is already here
if (true === $this->defaultInput->getOption('reset')) {
- $this->defaultOutput->writeln('Droping database, creating database and schema');
+ $this->defaultOutput->writeln('Droping database, creating database and schema, clearing the cache');
$this
->runCommand('doctrine:database:drop', array('--force' => true))
->runCommand('doctrine:database:create')
->runCommand('doctrine:schema:create')
+ ->runCommand('cache:clear')
;
+ $this->defaultOutput->writeln('');
+
return $this;
}
->runCommand('cache:clear')
;
+ $this->defaultOutput->writeln('');
+
return $this;
}
try {
$schemaManager = $connection->getSchemaManager();
} catch (\Exception $exception) {
+ // mysql & sqlite
if (false !== strpos($exception->getMessage(), sprintf("Unknown database '%s'", $databaseName))) {
return false;
}
+ // pgsql
+ if (false !== strpos($exception->getMessage(), sprintf('database "%s" does not exist', $databaseName))) {
+ return false;
+ }
+
throw $exception;
}
+++ /dev/null
-<?php
-
-namespace Wallabag\CoreBundle\Doctrine\Mapping;
-
-use Doctrine\ORM\Mapping\NamingStrategy;
-
-/**
- * Puts a prefix to each table.
- *
- * Solution from :
- * - http://stackoverflow.com/a/23860613/569101
- * - http://doctrine-orm.readthedocs.org/en/latest/reference/namingstrategy.html
- */
-class PrefixedNamingStrategy implements NamingStrategy
-{
- protected $prefix = '';
-
- public function __construct($prefix)
- {
- $this->prefix = (string) $prefix;
- }
-
- /**
- * {@inheritdoc}
- */
- public function classToTableName($className)
- {
- return strtolower($this->prefix.substr($className, strrpos($className, '\\') + 1));
- }
-
- /**
- * {@inheritdoc}
- */
- public function propertyToColumnName($propertyName, $className = null)
- {
- return $propertyName;
- }
-
- /**
- * {@inheritdoc}
- */
- public function referenceColumnName()
- {
- return 'id';
- }
-
- /**
- * {@inheritdoc}
- */
- public function joinColumnName($propertyName)
- {
- return $propertyName.'_'.$this->referenceColumnName();
- }
-
- /**
- * {@inheritdoc}
- */
- public function joinTableName($sourceEntity, $targetEntity, $propertyName = null)
- {
- // for join table we don't want to have both table concatenated AND prefixed
- // we just want the whole table to prefixed once
- // ie: not "wallabag_entry_wallabag_tag" but "wallabag_entry_tag"
- $target = substr($targetEntity, strrpos($targetEntity, '\\') + 1);
-
- return strtolower($this->classToTableName($sourceEntity).'_'.$target);
- }
-
- /**
- * {@inheritdoc}
- */
- public function joinKeyColumnName($entityName, $referencedColumnName = null)
- {
- return strtolower($this->classToTableName($entityName).'_'.($referencedColumnName ?: $this->referenceColumnName()));
- }
-
- /**
- * {@inheritdoc}
- */
- public function embeddedFieldToColumnName($propertyName, $embeddedColumnName, $className = null, $embeddedClassName = null)
- {
- return $propertyName.'_'.$embeddedColumnName;
- }
-}
* Config.
*
* @ORM\Entity(repositoryClass="Wallabag\CoreBundle\Repository\ConfigRepository")
- * @ORM\Table
+ * @ORM\Table(name="`config`")
* @ORM\Entity
*/
class Config
*
* @XmlRoot("entry")
* @ORM\Entity(repositoryClass="Wallabag\CoreBundle\Repository\EntryRepository")
- * @ORM\Table
+ * @ORM\Table(name="`entry`")
* @ORM\HasLifecycleCallbacks()
* @Hateoas\Relation("self", href = "expr('/api/entries/' ~ object.getId())")
*/
* Tag.
*
* @XmlRoot("tag")
- * @ORM\Table
+ * @ORM\Table(name="`tag`")
* @ORM\Entity(repositoryClass="Wallabag\CoreBundle\Repository\TagRepository")
* @ExclusionPolicy("all")
*/
arguments:
- @doctrine
- wallabag_core.doctrine.prefixed_naming_strategy:
- class: Wallabag\CoreBundle\Doctrine\Mapping\PrefixedNamingStrategy
+ wallabag_core.table_prefix_subscriber:
+ class: Wallabag\CoreBundle\Subscriber\TablePrefixSubscriber
arguments:
- %database_table_prefix%
+ tags:
+ - { name: doctrine.event_subscriber }
wallabag_core.graby:
class: Graby\Graby
--- /dev/null
+<?php
+
+namespace Wallabag\CoreBundle\Subscriber;
+
+use Doctrine\ORM\Event\LoadClassMetadataEventArgs;
+use Doctrine\Common\EventSubscriber;
+use Doctrine\ORM\Mapping\ClassMetadataInfo;
+
+/**
+ * Puts a prefix to each table.
+ * This way were used instead of using the built-in strategy from Doctrine, using `naming_strategy`
+ * Because it conflicts with the DefaultQuoteStrategy (that espace table name, like user for Postgres)
+ * see #1498 for more detail.
+ *
+ * Solution from :
+ * - http://stackoverflow.com/a/23860613/569101
+ * - http://doctrine-orm.readthedocs.org/en/latest/reference/namingstrategy.html
+ */
+class TablePrefixSubscriber implements EventSubscriber
+{
+ protected $prefix = '';
+
+ public function __construct($prefix)
+ {
+ $this->prefix = (string) $prefix;
+ }
+
+ public function getSubscribedEvents()
+ {
+ return array('loadClassMetadata');
+ }
+
+ public function loadClassMetadata(LoadClassMetadataEventArgs $args)
+ {
+ $classMetadata = $args->getClassMetadata();
+
+ // if we are in an inheritance hierarchy, only apply this once
+ if ($classMetadata->isInheritanceTypeSingleTable() && !$classMetadata->isRootEntity()) {
+ return;
+ }
+
+ $classMetadata->setTableName($this->prefix.$classMetadata->getTableName());
+
+ foreach ($classMetadata->getAssociationMappings() as $fieldName => $mapping) {
+ if ($mapping['type'] === ClassMetadataInfo::MANY_TO_MANY && isset($classMetadata->associationMappings[$fieldName]['joinTable']['name'])) {
+ $mappedTableName = $classMetadata->associationMappings[$fieldName]['joinTable']['name'];
+ $classMetadata->associationMappings[$fieldName]['joinTable']['name'] = $this->prefix.$mappedTableName;
+ }
+ }
+ }
+}
public function testRunInstallCommand()
{
- $this->container = static::$kernel->getContainer();
-
- $application = new Application(static::$kernel);
+ $application = new Application($this->getClient()->getKernel());
$application->add(new InstallCommandMock());
$command = $application->find('wallabag:install');
public function testRunInstallCommandWithReset()
{
- $this->container = static::$kernel->getContainer();
-
- $application = new Application(static::$kernel);
+ $application = new Application($this->getClient()->getKernel());
$application->add(new InstallCommandMock());
$command = $application->find('wallabag:install');
$this->assertContains('Step 4 of 4. Installing assets.', $tester->getDisplay());
// we force to reset everything
- $this->assertContains('Droping database, creating database and schema', $tester->getDisplay());
+ $this->assertContains('Droping database, creating database and schema, clearing the cache', $tester->getDisplay());
}
- /**
- * @group command-doctrine
- */
public function testRunInstallCommandWithDatabaseRemoved()
{
- $this->container = static::$kernel->getContainer();
-
- $application = new Application(static::$kernel);
- $application->add(new InstallCommand());
+ if ($this->getClient()->getContainer()->get('doctrine')->getConnection()->getDriver() instanceof \Doctrine\DBAL\Driver\PDOPgSql\Driver) {
+ /*
+ * LOG: statement: CREATE DATABASE "wallabag"
+ * ERROR: source database "template1" is being accessed by other users
+ * DETAIL: There is 1 other session using the database.
+ * STATEMENT: CREATE DATABASE "wallabag"
+ * FATAL: database "wallabag" does not exist
+ *
+ * http://stackoverflow.com/a/14374832/569101
+ */
+ $this->markTestSkipped('PostgreSQL spotted: can find a good way to drop current database, skipping.');
+ }
+
+ $application = new Application($this->getClient()->getKernel());
$application->add(new DropDatabaseDoctrineCommand());
// drop database first, so the install command won't ask to reset things
- $command = new DropDatabaseDoctrineCommand();
- $command->setApplication($application);
+ $command = $application->find('doctrine:database:drop');
$command->run(new ArrayInput(array(
'command' => 'doctrine:database:drop',
'--force' => true,
)), new NullOutput());
+ // start a new application to avoid lagging connexion to pgsql
+ $client = static::createClient();
+ $application = new Application($client->getKernel());
+ $application->add(new InstallCommand());
+
$command = $application->find('wallabag:install');
// We mock the QuestionHelper
public function testRunInstallCommandChooseResetSchema()
{
- $this->container = static::$kernel->getContainer();
-
- $application = new Application(static::$kernel);
+ $application = new Application($this->getClient()->getKernel());
$application->add(new InstallCommandMock());
$command = $application->find('wallabag:install');
$this->assertContains('Droping schema and creating schema', $tester->getDisplay());
}
- /**
- * @group command-doctrine
- */
public function testRunInstallCommandChooseNothing()
{
- $this->container = static::$kernel->getContainer();
-
- $application = new Application(static::$kernel);
+ if ($this->getClient()->getContainer()->get('doctrine')->getConnection()->getDriver() instanceof \Doctrine\DBAL\Driver\PDOPgSql\Driver) {
+ /*
+ * @see testRunInstallCommandWithDatabaseRemoved
+ */
+ $this->markTestSkipped('PostgreSQL spotted: can find a good way to drop current database, skipping.');
+ }
+
+ $application = new Application($this->getClient()->getKernel());
$application->add(new InstallCommand());
$application->add(new DropDatabaseDoctrineCommand());
$application->add(new CreateDatabaseDoctrineCommand());
'--force' => true,
)), new NullOutput());
- $this->container->get('doctrine')->getManager()->getConnection()->close();
+ $this->getClient()->getContainer()->get('doctrine')->getConnection()->close();
$command = new CreateDatabaseDoctrineCommand();
$command->setApplication($application);
public function testRunInstallCommandNoInteraction()
{
- $this->container = static::$kernel->getContainer();
-
- $application = new Application(static::$kernel);
+ $application = new Application($this->getClient()->getKernel());
$application->add(new InstallCommandMock());
$command = $application->find('wallabag:install');
$this->assertEquals('This value should not be blank.', $alert[0]);
}
+ /**
+ * This test will require an internet connection.
+ */
public function testPostNewOk()
{
$this->logInAs('admin');
$this->assertEquals(200, $client->getResponse()->getStatusCode());
}
+ /**
+ * @depends testPostNewOk
+ */
public function testView()
{
$this->logInAs('admin');
namespace Wallabag\CoreBundle\Tests\EventListener;
-use Symfony\Bundle\FrameworkBundle\Test\KernelTestCase;
use Symfony\Component\EventDispatcher\EventDispatcher;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpKernel\KernelEvents;
use Symfony\Component\HttpFoundation\Session\Session;
use Wallabag\CoreBundle\EventListener\LocaleListener;
-class LocaleListenerTest extends KernelTestCase
+class LocaleListenerTest extends \PHPUnit_Framework_TestCase
{
private function getEvent(Request $request)
{
namespace Wallabag\CoreBundle\Tests\EventListener;
-use Symfony\Bundle\FrameworkBundle\Test\KernelTestCase;
use Symfony\Component\EventDispatcher\EventDispatcher;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
use Wallabag\CoreBundle\Entity\Config;
use Wallabag\UserBundle\Entity\User;
-class RegistrationConfirmedListenerTest extends KernelTestCase
+class RegistrationConfirmedListenerTest extends \PHPUnit_Framework_TestCase
{
private $em;
private $listener;
namespace Wallabag\CoreBundle\Tests\EventListener;
-use Symfony\Bundle\FrameworkBundle\Test\KernelTestCase;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Session\Storage\MockArraySessionStorage;
use Symfony\Component\HttpFoundation\Session\Session;
use Wallabag\CoreBundle\Entity\Config;
use Wallabag\UserBundle\Entity\User;
-class UserLocaleListenerTest extends KernelTestCase
+class UserLocaleListenerTest extends \PHPUnit_Framework_TestCase
{
public function testWithLanguage()
{
namespace Wallabag\CoreBundle\Tests\Helper;
-use Symfony\Bundle\FrameworkBundle\Test\KernelTestCase;
use Wallabag\CoreBundle\Entity\Entry;
use Wallabag\UserBundle\Entity\User;
use Wallabag\CoreBundle\Helper\ContentProxy;
-class ContentProxyTest extends KernelTestCase
+class ContentProxyTest extends \PHPUnit_Framework_TestCase
{
public function testWithEmptyContent()
{
namespace Wallabag\CoreBundle\Tests\Command;
-use Symfony\Bundle\FrameworkBundle\Test\KernelTestCase;
use Wallabag\CoreBundle\ParamConverter\UsernameRssTokenConverter;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\ParamConverter;
use Symfony\Component\HttpFoundation\Request;
use Wallabag\UserBundle\Entity\User;
-class UsernameRssTokenConverterTest extends KernelTestCase
+class UsernameRssTokenConverterTest extends \PHPUnit_Framework_TestCase
{
public function testSupportsWithNoRegistry()
{
--- /dev/null
+<?php
+
+namespace Wallabag\CoreBundle\Tests\Subscriber;
+
+use Doctrine\ORM\Mapping\ClassMetadata;
+use Doctrine\ORM\Event\LoadClassMetadataEventArgs;
+use Doctrine\Common\EventManager;
+use Wallabag\CoreBundle\Subscriber\TablePrefixSubscriber;
+
+class TablePrefixSubscriberTest extends \PHPUnit_Framework_TestCase
+{
+ public function dataForPrefix()
+ {
+ return array(
+ array('wallabag_', 'Wallabag\UserBundle\Entity\User', '`user`', 'user', 'wallabag_user', '"wallabag_user"', new \Doctrine\DBAL\Platforms\PostgreSqlPlatform()),
+ array('wallabag_', 'Wallabag\UserBundle\Entity\User', '`user`', 'user', 'wallabag_user', '`wallabag_user`', new \Doctrine\DBAL\Platforms\MySqlPlatform()),
+ array('wallabag_', 'Wallabag\UserBundle\Entity\User', '`user`', 'user', 'wallabag_user', '"wallabag_user"', new \Doctrine\DBAL\Platforms\SqlitePlatform()),
+
+ array('wallabag_', 'Wallabag\UserBundle\Entity\User', 'user', 'user', 'wallabag_user', 'wallabag_user', new \Doctrine\DBAL\Platforms\PostgreSqlPlatform()),
+ array('wallabag_', 'Wallabag\UserBundle\Entity\User', 'user', 'user', 'wallabag_user', 'wallabag_user', new \Doctrine\DBAL\Platforms\MySqlPlatform()),
+ array('wallabag_', 'Wallabag\UserBundle\Entity\User', 'user', 'user', 'wallabag_user', 'wallabag_user', new \Doctrine\DBAL\Platforms\SqlitePlatform()),
+
+ array('', 'Wallabag\UserBundle\Entity\User', '`user`', 'user', 'user', '"user"', new \Doctrine\DBAL\Platforms\PostgreSqlPlatform()),
+ array('', 'Wallabag\UserBundle\Entity\User', '`user`', 'user', 'user', '`user`', new \Doctrine\DBAL\Platforms\MySqlPlatform()),
+ array('', 'Wallabag\UserBundle\Entity\User', '`user`', 'user', 'user', '"user"', new \Doctrine\DBAL\Platforms\SqlitePlatform()),
+
+ array('', 'Wallabag\UserBundle\Entity\User', 'user', 'user', 'user', 'user', new \Doctrine\DBAL\Platforms\PostgreSqlPlatform()),
+ array('', 'Wallabag\UserBundle\Entity\User', 'user', 'user', 'user', 'user', new \Doctrine\DBAL\Platforms\MySqlPlatform()),
+ array('', 'Wallabag\UserBundle\Entity\User', 'user', 'user', 'user', 'user', new \Doctrine\DBAL\Platforms\SqlitePlatform()),
+ );
+ }
+
+ /**
+ * @dataProvider dataForPrefix
+ */
+ public function testPrefix($prefix, $entityName, $tableName, $tableNameExpected, $finalTableName, $finalTableNameQuoted, $platform)
+ {
+ $em = $this->getMockBuilder('Doctrine\ORM\EntityManager')
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $subscriber = new TablePrefixSubscriber($prefix);
+
+ $metaClass = new ClassMetadata($entityName);
+ $metaClass->setPrimaryTable(array('name' => $tableName));
+
+ $metaDataEvent = new LoadClassMetadataEventArgs($metaClass, $em);
+
+ $this->assertEquals($tableNameExpected, $metaDataEvent->getClassMetadata()->getTableName());
+
+ $subscriber->loadClassMetadata($metaDataEvent);
+
+ $this->assertEquals($finalTableName, $metaDataEvent->getClassMetadata()->getTableName());
+ $this->assertEquals($finalTableNameQuoted, $metaDataEvent->getClassMetadata()->getQuotedTableName($platform));
+ }
+
+ /**
+ * @dataProvider dataForPrefix
+ */
+ public function testSubscribedEvents($prefix, $entityName, $tableName, $tableNameExpected, $finalTableName, $finalTableNameQuoted, $platform)
+ {
+ $em = $this->getMockBuilder('Doctrine\ORM\EntityManager')
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $metaClass = new ClassMetadata($entityName);
+ $metaClass->setPrimaryTable(array('name' => $tableName));
+
+ $metaDataEvent = new LoadClassMetadataEventArgs($metaClass, $em);
+
+ $subscriber = new TablePrefixSubscriber($prefix);
+
+ $evm = new EventManager();
+ $evm->addEventSubscriber($subscriber);
+
+ $evm->dispatchEvent('loadClassMetadata', $metaDataEvent);
+
+ $this->assertEquals($finalTableName, $metaDataEvent->getClassMetadata()->getTableName());
+ $this->assertEquals($finalTableNameQuoted, $metaDataEvent->getClassMetadata()->getQuotedTableName($platform));
+ }
+
+ public function testPrefixManyToMany()
+ {
+ $em = $this->getMockBuilder('Doctrine\ORM\EntityManager')
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $subscriber = new TablePrefixSubscriber('yo_');
+
+ $metaClass = new ClassMetadata('Wallabag\UserBundle\Entity\Entry');
+ $metaClass->setPrimaryTable(array('name' => 'entry'));
+ $metaClass->mapManyToMany(array(
+ 'fieldName' => 'tags',
+ 'joinTable' => array('name' => null, 'schema' => null),
+ 'targetEntity' => 'Tag',
+ 'mappedBy' => null,
+ 'inversedBy' => 'entries',
+ 'cascade' => array('persist'),
+ 'indexBy' => null,
+ 'orphanRemoval' => false,
+ 'fetch' => 2,
+ ));
+
+ $metaDataEvent = new LoadClassMetadataEventArgs($metaClass, $em);
+
+ $this->assertEquals('entry', $metaDataEvent->getClassMetadata()->getTableName());
+
+ $subscriber->loadClassMetadata($metaDataEvent);
+
+ $this->assertEquals('yo_entry', $metaDataEvent->getClassMetadata()->getTableName());
+ $this->assertEquals('yo_entry_tag', $metaDataEvent->getClassMetadata()->associationMappings['tags']['joinTable']['name']);
+ $this->assertEquals('yo_entry', $metaDataEvent->getClassMetadata()->getQuotedTableName(new \Doctrine\DBAL\Platforms\MySqlPlatform()));
+ }
+}
public function setUp()
{
+ parent::setUp();
+
$this->client = static::createClient();
}
* User.
*
* @ORM\Entity(repositoryClass="Wallabag\UserBundle\Repository\UserRepository")
- * @ORM\Table
+ * @ORM\Table(name="`user`")
* @ORM\HasLifecycleCallbacks()
* @ExclusionPolicy("all")
*