Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IBX-1334: Rebranded ibexa/core to use new namespaces #32

Merged
merged 4 commits into from
Dec 2, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
"symfony/expression-language": "^5.3.0",
"symfony/validator": "^5.3.0",
"symfony/var-dumper": "^5.3.0",
"ezsystems/doctrine-dbal-schema": "^4.0@dev",
"ibexa/doctrine-schema": "^4.0@dev",
"symfony-cmf/routing": "^2.3",
"guzzlehttp/guzzle": "^6.5",
"php-http/guzzle6-adapter": "^2.0",
Expand All @@ -63,7 +63,7 @@
"jenner/simple_fork": "^1.2",
"friends-of-behat/mink-extension": "^2.4",
"ibexa/ci-scripts": "^0.2@dev",
"ezsystems/ezplatform-code-style": "^2.0",
"ibexa/code-style": "^1.0",
"phpunit/phpunit": "^8.2",
"matthiasnoback/symfony-dependency-injection-test": "^4.1",
"symfony/phpunit-bridge": "^5.1",
Expand Down Expand Up @@ -125,7 +125,7 @@
},
"scripts": {
"check-cs": "@fix-cs --dry-run",
"fix-cs": "php-cs-fixer fix -v --show-progress=dots",
"fix-cs": "php-cs-fixer fix --config=.php-cs-fixer.php -v --show-progress=dots",
"unit": "phpunit -c phpunit.xml",
"integration": [
"Composer\\Config::disableProcessTimeout",
Expand Down
2 changes: 1 addition & 1 deletion phpunit-integration-legacy-solr.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
failOnWarning="true"
>
<php>
<env name="setupFactory" value="EzSystems\EzPlatformSolrSearchEngine\Tests\SetupFactory\LegacySetupFactory" />
<env name="setupFactory" value="Ibexa\Solr\LegacySetupFactory" />
<env name="backendVersion" value="5" />
<env name="fixtureDir" value="Solr" />
<env name="solrServer" value="http://localhost:8983/" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ abstract class AbstractParser implements ParserInterface
* You may here use $contextualizer->mapConfigArray().
*
* @see ConfigurationProcessor::mapConfig()
* @see ContextualizerInterface::mapConfigArray()
* @see \Ibexa\Bundle\Core\DependencyInjection\Configuration\SiteAccessAware\ContextualizerInterface::mapConfigArray()
*
* @param array $config Complete parsed semantic configuration
* @param \Ibexa\Bundle\Core\DependencyInjection\Configuration\SiteAccessAware\ContextualizerInterface $contextualizer
Expand All @@ -31,7 +31,7 @@ public function preMap(array $config, ContextualizerInterface $contextualizer)
* You may here use $contextualizer->mapConfigArray().
*
* @see ConfigurationProcessor::mapConfig()
* @see ContextualizerInterface::mapConfigArray()
* @see \Ibexa\Bundle\Core\DependencyInjection\Configuration\SiteAccessAware\ContextualizerInterface::mapConfigArray()
*
* @param array $config Complete parsed semantic configuration
* @param \Ibexa\Bundle\Core\DependencyInjection\Configuration\SiteAccessAware\ContextualizerInterface $contextualizer
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@

namespace Ibexa\Bundle\RepositoryInstaller\Event\Subscriber;

use EzSystems\DoctrineSchema\API\Event\SchemaBuilderEvent;
use EzSystems\DoctrineSchema\API\Event\SchemaBuilderEvents;
use Ibexa\Contracts\DoctrineSchema\Event\SchemaBuilderEvent;
use Ibexa\Contracts\DoctrineSchema\SchemaBuilderEvents;
use Symfony\Component\EventDispatcher\EventSubscriberInterface;

class BuildSchemaSubscriber implements EventSubscriberInterface
Expand Down Expand Up @@ -38,7 +38,7 @@ public static function getSubscribedEvents(): array
}

/**
* @param \EzSystems\DoctrineSchema\API\Event\SchemaBuilderEvent $event
* @param \Ibexa\Contracts\DoctrineSchema\Event\SchemaBuilderEvent $event
*/
public function onBuildSchema(SchemaBuilderEvent $event): void
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
*/
namespace Ibexa\Bundle\RepositoryInstaller;

use EzSystems\DoctrineSchemaBundle\DoctrineSchemaBundle;
use Ibexa\Bundle\DoctrineSchema\DoctrineSchemaBundle;
use Ibexa\Bundle\RepositoryInstaller\DependencyInjection\Compiler\InstallerTagPass;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Exception\RuntimeException;
Expand Down
10 changes: 5 additions & 5 deletions src/bundle/RepositoryInstaller/Installer/CoreInstaller.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,22 +12,22 @@
use Doctrine\DBAL\DBALException;
use Doctrine\DBAL\Platforms\AbstractPlatform;
use Doctrine\DBAL\Schema\Schema;
use EzSystems\DoctrineSchema\API\Builder\SchemaBuilder;
use Ibexa\Contracts\DoctrineSchema\Builder\SchemaBuilderInterface;
use Symfony\Component\Console\Helper\ProgressBar;

/**
* Installer which uses SchemaBuilder.
*/
class CoreInstaller extends DbBasedInstaller implements Installer
{
/** @var \EzSystems\DoctrineSchema\API\Builder\SchemaBuilder */
/** @var \Ibexa\Contracts\DoctrineSchema\Builder\SchemaBuilderInterface */
protected $schemaBuilder;

/**
* @param \Doctrine\DBAL\Connection $db
* @param \EzSystems\DoctrineSchema\API\Builder\SchemaBuilder $schemaBuilder
* @param \Ibexa\Contracts\DoctrineSchema\Builder\SchemaBuilderInterface $schemaBuilder
*/
public function __construct(Connection $db, SchemaBuilder $schemaBuilder)
public function __construct(Connection $db, SchemaBuilderInterface $schemaBuilder)
{
parent::__construct($db);

Expand All @@ -39,7 +39,7 @@ public function __construct(Connection $db, SchemaBuilder $schemaBuilder)
*
* If you wish to extend schema, implement your own EventSubscriber
*
* @see \EzSystems\DoctrineSchema\API\Event\SchemaBuilderEvent
* @see \Ibexa\Contracts\DoctrineSchema\Event\SchemaBuilderEvent
* @see \Ibexa\Bundle\RepositoryInstaller\Event\Subscriber\BuildSchemaSubscriber
*
* @throws \Doctrine\DBAL\DBALException
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,10 +92,10 @@ public function getSetVersionStatusQuery(
/**
* Create a select query to load Content Info data.
*
* @see Gateway::loadContentInfo()
* @see Gateway::loadContentInfoList()
* @see Gateway::loadContentInfoByRemoteId()
* @see Gateway::loadContentInfoByLocationId()
* @see \Ibexa\Core\Persistence\Legacy\Content\Gateway::loadContentInfo()
* @see \Ibexa\Core\Persistence\Legacy\Content\Gateway::loadContentInfoList()
* @see \Ibexa\Core\Persistence\Legacy\Content\Gateway::loadContentInfoByRemoteId()
* @see \Ibexa\Core\Persistence\Legacy\Content\Gateway::loadContentInfoByLocationId()
*/
public function createLoadContentInfoQueryBuilder(
bool $joinMainLocation = true
Expand Down
2 changes: 1 addition & 1 deletion src/lib/Repository/SearchService.php
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ public function findContent(Query $query, array $languageFilter = [], bool $filt
/**
* Finds contentInfo objects for the given query.
*
* @see SearchServiceInterface::findContentInfo()
* @see \Ibexa\Contracts\Core\Repository\SearchService::findContentInfo()
* @since 5.4.5
*
* @throws \Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException if query is not valid
Expand Down
4 changes: 2 additions & 2 deletions tests/bundle/Core/Resources/config/doctrine.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@

namespace Symfony\Component\DependencyInjection\Loader\Configurator;

use EzSystems\DoctrineSchema\Database\DbPlatform\PostgreSqlDbPlatform;
use EzSystems\DoctrineSchema\Database\DbPlatform\SqliteDbPlatform;
use Ibexa\DoctrineSchema\Database\DbPlatform\PostgreSqlDbPlatform;
use Ibexa\DoctrineSchema\Database\DbPlatform\SqliteDbPlatform;
use RuntimeException;

return static function (ContainerConfigurator $container): void {
Expand Down
4 changes: 2 additions & 2 deletions tests/bundle/Core/Resources/services/fixture-services.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ services:
arguments:
- '@doctrine.dbal.default_connection'

EzSystems\DoctrineSchema\Database\DbPlatform\SqliteDbPlatform:
Ibexa\DoctrineSchema\Database\DbPlatform\SqliteDbPlatform:
calls:
- [setEventManager, ['@doctrine.dbal.default_connection.event_manager']]

EzSystems\DoctrineSchema\Database\DbPlatform\PostgreSqlDbPlatform:
Ibexa\DoctrineSchema\Database\DbPlatform\PostgreSqlDbPlatform:
calls:
- [ setEventManager, [ '@doctrine.dbal.default_connection.event_manager' ] ]
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

namespace Ibexa\Tests\Bundle\RepositoryInstaller;

use EzSystems\DoctrineSchemaBundle\DependencyInjection\DoctrineSchemaExtension;
use Ibexa\Bundle\DoctrineSchema\DependencyInjection\DoctrineSchemaExtension;
use Ibexa\Bundle\RepositoryInstaller\DependencyInjection\Compiler\InstallerTagPass;
use Ibexa\Bundle\RepositoryInstaller\IbexaRepositoryInstallerBundle;
use PHPUnit\Framework\TestCase;
Expand Down
2 changes: 1 addition & 1 deletion tests/integration/Core/Repository/BaseTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -530,7 +530,7 @@ protected function refreshSearch(Repository $repository)
$searchHandlerProperty = new \ReflectionProperty($repository, 'searchHandler');
$searchHandlerProperty->setAccessible(true);

/** @var \EzSystems\EzPlatformSolrSearchEngine\Handler $searchHandler */
/** @var \Ibexa\Solr\Handler $searchHandler */
$searchHandler = $searchHandlerProperty->getValue($repository);

$searchHandler->commit();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@
*/
namespace Ibexa\Tests\Integration\Core\Repository\Regression;

use EzSystems\EzPlatformSolrSearchEngine\Tests\SetupFactory\LegacySetupFactory;
use Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException;
use Ibexa\Contracts\Core\Repository\Values\Content\Query;
use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\LanguageCode;
use Ibexa\Solr\LegacySetupFactory;
use Ibexa\Tests\Integration\Core\Repository\BaseTest;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
*/
namespace Ibexa\Tests\Integration\Core\Repository;

use EzSystems\EzPlatformSolrSearchEngine\Tests\SetupFactory\LegacySetupFactory as LegacySolrSetupFactory;
use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException;
use Ibexa\Contracts\Core\Repository\Exceptions\NotImplementedException;
use Ibexa\Contracts\Core\Repository\Values\Content\Content;
Expand All @@ -17,6 +16,7 @@
use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchResult;
use Ibexa\Contracts\Core\Test\Repository\SetupFactory\Legacy;
use Ibexa\Core\Repository\Values\Content\Location;
use Ibexa\Solr\LegacySetupFactory as LegacySolrSetupFactory;
use Ibexa\Tests\Core\Repository\Common;

/**
Expand Down
2 changes: 1 addition & 1 deletion tests/integration/Core/Repository/SearchServiceTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
namespace Ibexa\Tests\Integration\Core\Repository;

use function count;
use EzSystems\EzPlatformSolrSearchEngine\Tests\SetupFactory\LegacySetupFactory as LegacySolrSetupFactory;
use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException;
use Ibexa\Contracts\Core\Repository\Exceptions\NotImplementedException;
use Ibexa\Contracts\Core\Repository\Values\Content\Content;
Expand All @@ -21,6 +20,7 @@
use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchHit;
use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchResult;
use Ibexa\Contracts\Core\Test\Repository\SetupFactory\Legacy;
use Ibexa\Solr\LegacySetupFactory as LegacySolrSetupFactory;
use Ibexa\Tests\Core\Repository\Common;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@
namespace Ibexa\Tests\Integration\Core\Repository;

use DateTime;
use EzSystems\EzPlatformSolrSearchEngine\Tests\SetupFactory\LegacySetupFactory as LegacySolrSetupFactory;
use Ibexa\Contracts\Core\Repository\Values\Content\LocationQuery;
use Ibexa\Contracts\Core\Repository\Values\Content\Query;
use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion;
use Ibexa\Contracts\Core\Repository\Values\Content\Query\SortClause;
use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchHit;
use Ibexa\Solr\LegacySetupFactory as LegacySolrSetupFactory;
use RuntimeException;

/**
Expand Down
1 change: 0 additions & 1 deletion tests/integration/Core/Repository/URLAliasServiceTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -1199,7 +1199,6 @@ public function testRefreshSystemUrlAliasesForContentsWithUpdatedContentTypes()
list($topFolderLocation, $nestedFolderLocation) = $this->testLookupOnMultilingualNestedLocations();
/** @var \Ibexa\Contracts\Core\Repository\Values\Content\Location $topFolderLocation */
/** @var \Ibexa\Contracts\Core\Repository\Values\Content\Location $nestedFolderLocation */

// Default URL Alias schema is <short_name|name> which messes up this test, so:
$this->changeContentTypeUrlAliasSchema('folder', '<name>');

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ services:

# repeat part of DIC setup to avoid loading DoctrineSchemaBundle
_instanceof:
EzSystems\DoctrineSchema\Database\DbPlatform\DbPlatform:
Ibexa\DoctrineSchema\Database\DbPlatform\DbPlatformInterface:
tags: ['doctrine.dbplatform']

Symfony\Component\EventDispatcher\EventDispatcher:
Expand All @@ -36,7 +36,7 @@ services:

Doctrine\Common\EventManager: ~

EzSystems\DoctrineSchema\Database\DbPlatform\SqliteDbPlatform:
Ibexa\DoctrineSchema\Database\DbPlatform\SqliteDbPlatform:
autowire: true

Ibexa\Tests\Core\Persistence\DatabaseConnectionFactory:
Expand Down
2 changes: 1 addition & 1 deletion tests/lib/Persistence/DatabaseConnectionFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class DatabaseConnectionFactory
private static $connectionPool;

/**
* @param \EzSystems\DoctrineSchema\Database\DbPlatform\DbPlatform[] $databasePlatforms
* @param \Ibexa\DoctrineSchema\Database\DbPlatform\DbPlatformInterface[] $databasePlatforms
* @param \Doctrine\Common\EventManager $eventManager
*/
public function __construct(iterable $databasePlatforms, EventManager $eventManager)
Expand Down
2 changes: 1 addition & 1 deletion tests/lib/Persistence/Legacy/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
use Doctrine\DBAL\DBALException;
use Doctrine\DBAL\FetchMode;
use Doctrine\DBAL\Query\QueryBuilder;
use EzSystems\DoctrineSchema\Database\DbPlatform\SqliteDbPlatform;
use Ibexa\Contracts\Core\Test\Persistence\Fixture\FileFixtureFactory;
use Ibexa\Contracts\Core\Test\Persistence\Fixture\FixtureImporter;
use Ibexa\Contracts\Core\Test\Persistence\Fixture\YamlFixture;
Expand All @@ -22,6 +21,7 @@
use Ibexa\Core\Search\Legacy\Content\Common\Gateway\CriteriaConverter;
use Ibexa\Core\Search\Legacy\Content\Common\Gateway\CriterionHandler;
use Ibexa\Core\Search\Legacy\Content\Common\Gateway\SortClauseConverter;
use Ibexa\DoctrineSchema\Database\DbPlatform\SqliteDbPlatform;
use Ibexa\Tests\Core\Persistence\DatabaseConnectionFactory;
use Ibexa\Tests\Core\Repository\LegacySchemaImporter;
use InvalidArgumentException;
Expand Down
4 changes: 2 additions & 2 deletions tests/lib/Repository/LegacySchemaImporter.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
use Doctrine\DBAL\DBALException;
use Doctrine\DBAL\Platforms\AbstractPlatform;
use Doctrine\DBAL\Schema\Schema as DoctrineSchema;
use EzSystems\DoctrineSchema\API\Exception\InvalidConfigurationException;
use EzSystems\DoctrineSchema\Importer\SchemaImporter;
use Ibexa\Contracts\DoctrineSchema\Exception\InvalidConfigurationException;
use Ibexa\DoctrineSchema\Importer\SchemaImporter;
use RuntimeException;

/**
Expand Down