File tree Expand file tree Collapse file tree 1 file changed +24
-0
lines changed
spec/Packagist/Api/Result/Package Expand file tree Collapse file tree 1 file changed +24
-0
lines changed Original file line number Diff line number Diff line change @@ -43,4 +43,28 @@ public function it_gets_shasum()
4343 {
4444 $ this ->getShasum ()->shouldReturn ('cb0a489db41707d5df078f1f35e028e04ffd9e8e ' );
4545 }
46+
47+ public function it_can_deal_with_nullable_reference ()
48+ {
49+ $ this ->fromArray ([
50+ 'type ' => 'git ' ,
51+ 'url ' => 'https://github.com/Sylius/Sylius.git ' ,
52+ 'reference ' => null ,
53+ 'shasum ' => 'cb0a489db41707d5df078f1f35e028e04ffd9e8e ' ,
54+ ]);
55+
56+ $ this ->getReference ()->shouldReturn (null );
57+ }
58+
59+ public function it_can_deal_with_nullable_shasum ()
60+ {
61+ $ this ->fromArray ([
62+ 'type ' => 'git ' ,
63+ 'url ' => 'https://github.com/Sylius/Sylius.git ' ,
64+ 'reference ' => 'cb0a489db41707d5df078f1f35e028e04ffd9e8e ' ,
65+ 'shasum ' => null ,
66+ ]);
67+
68+ $ this ->getShasum ()->shouldReturn (null );
69+ }
4670}
You can’t perform that action at this time.
0 commit comments