mirror of
https://github.com/flarum/core.git
synced 2025-08-13 03:44:32 +02:00
Use flarum/testing for test infrastructure (#2545)
This commit is contained in:
committed by
GitHub
parent
bc607e089e
commit
2c3e1f9923
@@ -10,7 +10,7 @@
|
||||
namespace Flarum\Tests\unit\Foundation;
|
||||
|
||||
use Flarum\Foundation\Config;
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
use InvalidArgumentException;
|
||||
use RuntimeException;
|
||||
|
||||
|
@@ -10,7 +10,7 @@
|
||||
namespace Flarum\Tests\unit\Foundation;
|
||||
|
||||
use Flarum\Foundation\ContainerUtil;
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
use Illuminate\Container\Container;
|
||||
|
||||
class ContainerUtilTest extends TestCase
|
||||
|
@@ -10,7 +10,7 @@
|
||||
namespace Flarum\Tests\unit\Foundation\ErrorHandling\ExceptionHandler;
|
||||
|
||||
use Flarum\Foundation\ErrorHandling\ExceptionHandler\IlluminateValidationExceptionHandler;
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
use Illuminate\Translation\ArrayLoader;
|
||||
use Illuminate\Translation\Translator;
|
||||
use Illuminate\Validation\Factory;
|
||||
|
@@ -11,7 +11,7 @@ namespace Flarum\Tests\unit\Foundation\ErrorHandling\ExceptionHandler;
|
||||
|
||||
use Flarum\Foundation\ErrorHandling\ExceptionHandler\ValidationExceptionHandler;
|
||||
use Flarum\Foundation\ValidationException;
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
|
||||
class ValidationExceptionHandlerTest extends TestCase
|
||||
{
|
||||
|
@@ -10,7 +10,7 @@
|
||||
namespace Flarum\Tests\unit\Foundation;
|
||||
|
||||
use Flarum\Extension\ExtensionManager;
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
|
||||
class ExtensionDependencyResolutionTest extends TestCase
|
||||
{
|
||||
|
@@ -10,7 +10,7 @@
|
||||
namespace Flarum\Tests\unit\Foundation;
|
||||
|
||||
use Flarum\Foundation\Paths;
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
use InvalidArgumentException;
|
||||
|
||||
class PathsTest extends TestCase
|
||||
|
@@ -10,7 +10,7 @@
|
||||
namespace Flarum\Tests\unit\Foundation;
|
||||
|
||||
use Flarum\Http\RouteCollection;
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
use RuntimeException;
|
||||
|
||||
class RouteCollectionTest extends TestCase
|
||||
|
@@ -12,7 +12,7 @@ namespace Flarum\Tests\unit\Http;
|
||||
use Carbon\Carbon;
|
||||
use Flarum\Foundation\Config;
|
||||
use Flarum\Http\CookieFactory;
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
|
||||
class CookieFactoryTest extends TestCase
|
||||
{
|
||||
|
@@ -10,7 +10,7 @@
|
||||
namespace Flarum\Tests\unit\Http;
|
||||
|
||||
use Flarum\Http\RouteCollection;
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
|
||||
class RouteCollectionTest extends TestCase
|
||||
{
|
||||
|
@@ -10,7 +10,7 @@
|
||||
namespace Flarum\Tests\unit\Install;
|
||||
|
||||
use Flarum\Install\BaseUrl;
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
use Laminas\Diactoros\Uri;
|
||||
|
||||
class BaseUrlTest extends TestCase
|
||||
|
@@ -10,7 +10,7 @@
|
||||
namespace Flarum\Tests\unit\Install\Prerequisite;
|
||||
|
||||
use Flarum\Install\Prerequisite\WritablePaths;
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
|
||||
class WritablePathsTest extends TestCase
|
||||
{
|
||||
|
@@ -10,7 +10,7 @@
|
||||
namespace Flarum\Tests\unit\Settings;
|
||||
|
||||
use Flarum\Settings\DatabaseSettingsRepository;
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
use Illuminate\Database\ConnectionInterface;
|
||||
use Mockery as m;
|
||||
|
||||
|
@@ -11,7 +11,7 @@ namespace Flarum\Tests\unit\Settings;
|
||||
|
||||
use Flarum\Settings\MemoryCacheSettingsRepository;
|
||||
use Flarum\Settings\SettingsRepositoryInterface;
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
use Mockery as m;
|
||||
|
||||
class MemoryCacheSettingsRepositoryTest extends TestCase
|
||||
|
@@ -1,18 +0,0 @@
|
||||
<?php
|
||||
|
||||
/*
|
||||
* This file is part of Flarum.
|
||||
*
|
||||
* For detailed copyright and license information, please view the
|
||||
* LICENSE file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Flarum\Tests\unit;
|
||||
|
||||
use Mockery\Adapter\Phpunit\MockeryPHPUnitIntegration;
|
||||
|
||||
abstract class TestCase extends \PHPUnit\Framework\TestCase
|
||||
{
|
||||
// Ensure Mockery is always torn down automatically after each test.
|
||||
use MockeryPHPUnitIntegration;
|
||||
}
|
@@ -9,7 +9,7 @@
|
||||
|
||||
namespace Flarum\Tests\unit\User;
|
||||
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
use Flarum\User\Access\AbstractPolicy;
|
||||
use Flarum\User\User;
|
||||
use Illuminate\Events\Dispatcher;
|
||||
|
@@ -9,7 +9,7 @@
|
||||
|
||||
namespace Flarum\Tests\unit\User;
|
||||
|
||||
use Flarum\Tests\unit\TestCase;
|
||||
use Flarum\Testing\unit\TestCase;
|
||||
use Flarum\User\AvatarUploader;
|
||||
use Flarum\User\User;
|
||||
use Illuminate\Contracts\Events\Dispatcher;
|
||||
|
Reference in New Issue
Block a user