File tree Expand file tree Collapse file tree 2 files changed +9
-11
lines changed Expand file tree Collapse file tree 2 files changed +9
-11
lines changed Original file line number Diff line number Diff line change @@ -71,7 +71,7 @@ parameters:
7171 path : src/Models/Transfer.php
7272
7373 -
74- message : " #^Call to an undefined method Illuminate \\\\ Database \\\\ Eloquent \\\\ Relations \\\\ MorphOne \\ : \\ :withTrashed \\ ( \\ ) \\ .$#"
74+ message : " #^Cannot call method getDynamicDefaultSlug \\ ( \\ ) on class \\ -string \\ |object \\ .$#"
7575 count : 2
7676 path : src/Models/Wallet.php
7777
@@ -85,16 +85,6 @@ parameters:
8585 count : 1
8686 path : src/Models/Wallet.php
8787
88- -
89- message : " #^Parameter \\ #1 \\ $related of method Illuminate\\\\ Database\\\\ Eloquent\\\\ Model\\ :\\ :hasMany\\ (\\ ) expects string, mixed given\\ .$#"
90- count : 6
91- path : src/Models/Wallet.php
92-
93- -
94- message : " #^Parameter \\ #1 \\ $related of method Illuminate\\\\ Database\\\\ Eloquent\\\\ Model\\ :\\ :morphMany\\ (\\ ) expects string, mixed given\\ .$#"
95- count : 2
96- path : src/Models/Wallet.php
97-
9888 -
9989 message : " #^Parameter \\ #1 \\ .\\ .\\ .\\ $arrays of function array_merge expects array, mixed given\\ .$#"
10090 count : 2
Original file line number Diff line number Diff line change @@ -306,11 +306,19 @@ public function testGetDynamicDefaultSlug(): void
306306 {
307307 /** @var UserDynamic $user */
308308 $ user = UserDynamicFactory::new ()->create ();
309+ self ::assertFalse ($ user ->relationLoaded ('wallet ' ));
309310
310311 self ::assertNotNull ($ user ->deposit (100 ));
311312 self ::assertSame (100 , $ user ->balanceInt );
312313
314+ self ::assertTrue ($ user ->relationLoaded ('wallet ' ));
313315 self ::assertSame ('default- ' .$ user ->email , $ user ->wallet ->slug );
316+
317+ /** @var UserDynamic $userFound */
318+ $ userFound = UserDynamic::query ()->find ($ user ->getKey ());
319+
320+ self ::assertFalse ($ userFound ->relationLoaded ('wallet ' ));
321+ self ::assertSame ('default- ' .$ user ->email , $ userFound ->wallet ->slug );
314322 }
315323
316324 public function testCrash (): void
You can’t perform that action at this time.
0 commit comments