mirror of https://github.com/FriendsOfTYPO3/tea.git synced 2024-11-22 18:36:13 +01:00

[TASK] Convert the PHP namespaces to "TTN" (#9)

Fixes #1
This commit is contained in:
Oliver Klee 2019-12-01 12:16:06 +01:00 committed by GitHub
parent 691229fb2a
commit 29bf7ccae5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
15 changed files with 27 additions and 26 deletions

View file

@ -15,6 +15,7 @@ This project adheres to [Semantic Versioning](https://semver.org/).
- Composer script for PHP linting - Composer script for PHP linting
### Changed ### Changed
- Convert the PHP namespaces to "TTN" (#8)
- Update the contact email in the CoC document (#6) - Update the contact email in the CoC document (#6)
- Switch to the `TTN` PHP vendor namespace (#1, #5) - Switch to the `TTN` PHP vendor namespace (#1, #5)
- Sort the Composer dependencies - Sort the Composer dependencies

View file

@ -1,10 +1,10 @@
<?php <?php
declare(strict_types=1); declare(strict_types=1);
namespace OliverKlee\Tea\Controller; namespace TTN\Tea\Controller;
use OliverKlee\Tea\Domain\Model\Product\Tea; use TTN\Tea\Domain\Model\Product\Tea;
use OliverKlee\Tea\Domain\Repository\Product\TeaRepository; use TTN\Tea\Domain\Repository\Product\TeaRepository;
use TYPO3\CMS\Extbase\Mvc\Controller\ActionController; use TYPO3\CMS\Extbase\Mvc\Controller\ActionController;
/** /**

View file

@ -1,7 +1,7 @@
<?php <?php
declare(strict_types=1); declare(strict_types=1);
namespace OliverKlee\Tea\Domain\Model\Product; namespace TTN\Tea\Domain\Model\Product;
use TYPO3\CMS\Extbase\Annotation\ORM\Lazy; use TYPO3\CMS\Extbase\Annotation\ORM\Lazy;
use TYPO3\CMS\Extbase\Domain\Model\FileReference; use TYPO3\CMS\Extbase\Domain\Model\FileReference;

View file

@ -1,9 +1,9 @@
<?php <?php
declare(strict_types=1); declare(strict_types=1);
namespace OliverKlee\Tea\Domain\Repository\Product; namespace TTN\Tea\Domain\Repository\Product;
use OliverKlee\Tea\Domain\Repository\Traits\StoragePageAgnosticTrait; use TTN\Tea\Domain\Repository\Traits\StoragePageAgnosticTrait;
use TYPO3\CMS\Extbase\Persistence\QueryInterface; use TYPO3\CMS\Extbase\Persistence\QueryInterface;
use TYPO3\CMS\Extbase\Persistence\Repository; use TYPO3\CMS\Extbase\Persistence\Repository;

View file

@ -1,7 +1,7 @@
<?php <?php
declare(strict_types=1); declare(strict_types=1);
namespace OliverKlee\Tea\Domain\Repository\Traits; namespace TTN\Tea\Domain\Repository\Traits;
use TYPO3\CMS\Extbase\Object\ObjectManagerInterface; use TYPO3\CMS\Extbase\Object\ObjectManagerInterface;
use TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface; use TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface;

View file

@ -4,7 +4,7 @@ defined('TYPO3_MODE') or die();
// This makes the plugin selectable in the BE. // This makes the plugin selectable in the BE.
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::registerPlugin( \TYPO3\CMS\Extbase\Utility\ExtensionUtility::registerPlugin(
// extension name, exactly matching the PHP namespaces (vendor and product) // extension name, exactly matching the PHP namespaces (vendor and product)
'OliverKlee.Tea', 'TTN.Tea',
// arbitrary, but unique plugin name (not visible in the BE) // arbitrary, but unique plugin name (not visible in the BE)
'Tea', 'Tea',
// plugin title, as visible in the drop-down in the BE // plugin title, as visible in the drop-down in the BE

View file

@ -1,7 +1,7 @@
<?php <?php
declare(strict_types=1); declare(strict_types=1);
namespace OliverKlee\Tea\Tests\Acceptance; namespace TTN\Tea\Tests\Acceptance;
/** /**
* Test case. * Test case.

View file

@ -1,7 +1,7 @@
<?php <?php
declare(strict_types=1); declare(strict_types=1);
namespace OliverKlee\Tea\Tests\Functional\Controller; namespace TTN\Tea\Tests\Functional\Controller;
use Nimut\TestingFramework\TestCase\FunctionalTestCase; use Nimut\TestingFramework\TestCase\FunctionalTestCase;

View file

@ -1,11 +1,11 @@
<?php <?php
declare(strict_types=1); declare(strict_types=1);
namespace OliverKlee\Tea\Tests\Functional\Domain\Repository\Product; namespace TTN\Tea\Tests\Functional\Domain\Repository\Product;
use Nimut\TestingFramework\TestCase\FunctionalTestCase; use Nimut\TestingFramework\TestCase\FunctionalTestCase;
use OliverKlee\Tea\Domain\Model\Product\Tea; use TTN\Tea\Domain\Model\Product\Tea;
use OliverKlee\Tea\Domain\Repository\Product\TeaRepository; use TTN\Tea\Domain\Repository\Product\TeaRepository;
use TYPO3\CMS\Core\Utility\GeneralUtility; use TYPO3\CMS\Core\Utility\GeneralUtility;
use TYPO3\CMS\Extbase\Domain\Model\FileReference; use TYPO3\CMS\Extbase\Domain\Model\FileReference;
use TYPO3\CMS\Extbase\Object\ObjectManager; use TYPO3\CMS\Extbase\Object\ObjectManager;

View file

@ -1,12 +1,12 @@
<?php <?php
declare(strict_types=1); declare(strict_types=1);
namespace OliverKlee\Tea\Tests\Unit\Controller; namespace TTN\Tea\Tests\Unit\Controller;
use Nimut\TestingFramework\TestCase\UnitTestCase; use Nimut\TestingFramework\TestCase\UnitTestCase;
use OliverKlee\Tea\Controller\TeaController; use TTN\Tea\Controller\TeaController;
use OliverKlee\Tea\Domain\Model\Product\Tea; use TTN\Tea\Domain\Model\Product\Tea;
use OliverKlee\Tea\Domain\Repository\Product\TeaRepository; use TTN\Tea\Domain\Repository\Product\TeaRepository;
use Prophecy\Prophecy\ObjectProphecy; use Prophecy\Prophecy\ObjectProphecy;
use Prophecy\Prophecy\ProphecySubjectInterface; use Prophecy\Prophecy\ProphecySubjectInterface;
use TYPO3\CMS\Extbase\Mvc\Controller\ActionController; use TYPO3\CMS\Extbase\Mvc\Controller\ActionController;

View file

@ -1,10 +1,10 @@
<?php <?php
declare(strict_types=1); declare(strict_types=1);
namespace OliverKlee\Tea\Tests\Unit\Domain\Model\Product; namespace TTN\Tea\Tests\Unit\Domain\Model\Product;
use Nimut\TestingFramework\TestCase\UnitTestCase; use Nimut\TestingFramework\TestCase\UnitTestCase;
use OliverKlee\Tea\Domain\Model\Product\Tea; use TTN\Tea\Domain\Model\Product\Tea;
use TYPO3\CMS\Extbase\Domain\Model\FileReference; use TYPO3\CMS\Extbase\Domain\Model\FileReference;
use TYPO3\CMS\Extbase\DomainObject\AbstractEntity; use TYPO3\CMS\Extbase\DomainObject\AbstractEntity;

View file

@ -1,10 +1,10 @@
<?php <?php
declare(strict_types=1); declare(strict_types=1);
namespace OliverKlee\Tea\Tests\Unit\Domain\Repository\Product; namespace TTN\Tea\Tests\Unit\Domain\Repository\Product;
use Nimut\TestingFramework\TestCase\UnitTestCase; use Nimut\TestingFramework\TestCase\UnitTestCase;
use OliverKlee\Tea\Domain\Repository\Product\TeaRepository; use TTN\Tea\Domain\Repository\Product\TeaRepository;
use Prophecy\Prophecy\ProphecySubjectInterface; use Prophecy\Prophecy\ProphecySubjectInterface;
use TYPO3\CMS\Extbase\Object\ObjectManagerInterface; use TYPO3\CMS\Extbase\Object\ObjectManagerInterface;
use TYPO3\CMS\Extbase\Persistence\Repository; use TYPO3\CMS\Extbase\Persistence\Repository;

View file

@ -46,12 +46,12 @@
}, },
"autoload": { "autoload": {
"psr-4": { "psr-4": {
"OliverKlee\\Tea\\": "Classes/" "TTN\\Tea\\": "Classes/"
} }
}, },
"autoload-dev": { "autoload-dev": {
"psr-4": { "psr-4": {
"OliverKlee\\Tea\\Tests\\": "Tests/" "TTN\\Tea\\Tests\\": "Tests/"
} }
}, },
"prefer-stable": true, "prefer-stable": true,

View file

@ -18,12 +18,12 @@ $EM_CONF[$_EXTKEY] = [
'author_company' => 'TYPO3 Trainer Network', 'author_company' => 'TYPO3 Trainer Network',
'autoload' => [ 'autoload' => [
'psr-4' => [ 'psr-4' => [
'OliverKlee\\Tea\\' => 'Classes/', 'TTN\\Tea\\' => 'Classes/',
], ],
], ],
'autoload-dev' => [ 'autoload-dev' => [
'psr-4' => [ 'psr-4' => [
'OliverKlee\\Tea\\Tests\\' => 'Tests/', 'TTN\\Tea\\Tests\\' => 'Tests/',
], ],
], ],
]; ];

View file

@ -2,7 +2,7 @@
// This makes the plugin available for front-end rendering. // This makes the plugin available for front-end rendering.
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::configurePlugin( \TYPO3\CMS\Extbase\Utility\ExtensionUtility::configurePlugin(
// extension name, exactly matching the PHP namespaces (vendor and product) // extension name, exactly matching the PHP namespaces (vendor and product)
'OliverKlee.Tea', 'TTN.Tea',
// arbitrary, but unique plugin name (not visible in the BE) // arbitrary, but unique plugin name (not visible in the BE)
'Tea', 'Tea',
// all actions // all actions