Commit 788ec41 1 parent 15dc438 commit 788ec41 Copy full SHA for 788ec41
File tree 1 file changed +31
-0
lines changed
service-api/app/test/AppTest/Entity/Value
1 file changed +31
-0
lines changed Original file line number Diff line number Diff line change
1
+ <?php
2
+
3
+ declare (strict_types=1 );
4
+
5
+ namespace AppTest \Entity \Value ;
6
+
7
+ use App \Entity \Value \LpaUid ;
8
+ use App \Enum \LpaSource ;
9
+ use PHPUnit \Framework \Attributes \DataProvider ;
10
+ use PHPUnit \Framework \Attributes \Test ;
11
+ use PHPUnit \Framework \TestCase ;
12
+
13
+ class LpaUidTest extends TestCase
14
+ {
15
+ #[Test]
16
+ #[DataProvider('lpaData ' )]
17
+ public function it_correctly_identifies_the_lpa_type (string $ uid , LpaSource $ source ): void
18
+ {
19
+ $ sut = new LpaUid ($ uid );
20
+
21
+ $ this ->assertEquals ($ source , $ sut ->getLpaSource ());
22
+ }
23
+
24
+ public static function lpaData (): array
25
+ {
26
+ return [
27
+ 'sirius type ' => ['700000000047 ' , LpaSource::SIRIUS ],
28
+ 'lpa store type ' => ['M-789Q-P4DF-4UX3 ' , LpaSource::LPASTORE ],
29
+ ];
30
+ }
31
+ }
You can’t perform that action at this time.
0 commit comments