Skip to content

Commit

Permalink
Arch test serializers/generators
Browse files Browse the repository at this point in the history
  • Loading branch information
rawilk committed Sep 27, 2023
1 parent c31a582 commit 795b9f4
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions tests/ArchTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@

use Illuminate\Database\Eloquent\Model;
use Illuminate\Support\Facades\Facade;
use Rawilk\Settings\Contracts\ContextSerializer;
use Rawilk\Settings\Contracts\Driver;
use Rawilk\Settings\Contracts\KeyGenerator;
use Rawilk\Settings\Drivers\Factory;

it('will not use debugging functions')
Expand Down Expand Up @@ -36,3 +38,19 @@
->classes()
->toExtend(Model::class)
->not->toBeFinal();

test('context serializers are configured correctly')
->expect('Rawilk\Settings\Support\ContextSerializers')
->toBeClasses()
->classes()
->toImplement(ContextSerializer::class)
->toExtendNothing()
->toHaveSuffix('Serializer');

test('key generators are configured correctly')
->expect('Rawilk\Settings\Support\KeyGenerators')
->toBeClasses()
->classes()
->toImplement(KeyGenerator::class)
->toExtendNothing()
->toHaveSuffix('Generator');

0 comments on commit 795b9f4

Please sign in to comment.