From 7091772f39e8f1d8cb6dd7f49a075e9cd6f445be Mon Sep 17 00:00:00 2001 From: Joey McKenzie Date: Thu, 29 Feb 2024 22:20:47 -0800 Subject: [PATCH] tests: add immutable response --- tests/Arch.php | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/tests/Arch.php b/tests/Arch.php index 9cb689bd..fa05e9ae 100644 --- a/tests/Arch.php +++ b/tests/Arch.php @@ -4,9 +4,13 @@ namespace Tests; -test('All source files are strictly typed')->expect('OpenBreweryDb\\')->toUseStrictTypes(); +test('All source files are strictly typed') + ->expect('OpenBreweryDb\\') + ->toUseStrictTypes(); -test('All tests files are strictly typed')->expect('Tests\\')->toUseStrictTypes(); +test('All tests files are strictly typed') + ->expect('Tests\\') + ->toUseStrictTypes(); test('Value objects should be immutable') ->expect('OpenBreweryDb\\ValueObjects\\') @@ -14,6 +18,12 @@ ->and('OpenBreweryDb\\ValueObjects\\') ->toBeReadonly(); +test('Responses should be immutable') + ->expect('OpenBreweryDb\\Responses\\Breweries\\') + ->toBeFinal() + ->and('OpenBreweryDb\\Responses\\Breweries\\') + ->toBeReadonly(); + test('Contracts should be abstract') ->expect('OpenBreweryDb\\Contracts\\') ->toBeInterfaces();