mirror of
https://github.com/shlinkio/shlink.git
synced 2026-03-12 01:54:41 +08:00
Moved common data provider for core unit tests to trait
This commit is contained in:
16
module/Core/test/Util/ApiKeyHelpersTrait.php
Normal file
16
module/Core/test/Util/ApiKeyHelpersTrait.php
Normal file
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace ShlinkioTest\Shlink\Core\Util;
|
||||
|
||||
use Shlinkio\Shlink\Rest\Entity\ApiKey;
|
||||
|
||||
trait ApiKeyHelpersTrait
|
||||
{
|
||||
public function provideAdminApiKeys(): iterable
|
||||
{
|
||||
yield 'no API key' => [null];
|
||||
yield 'admin API key' => [new ApiKey()];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user