File tree Expand file tree Collapse file tree 2 files changed +44
-0
lines changed
Expand file tree Collapse file tree 2 files changed +44
-0
lines changed Original file line number Diff line number Diff line change 1+ <?php
2+
3+ declare (strict_types=1 );
4+
5+ namespace Bavix \Wallet \Test \Infra \PackageModels ;
6+
7+ final class MyWallet extends \Bavix \Wallet \Models \Wallet
8+ {
9+ public function helloWorld (): string
10+ {
11+ return 'hello world ' ;
12+ }
13+ }
Original file line number Diff line number Diff line change 1+ <?php
2+
3+ declare (strict_types=1 );
4+
5+ namespace Bavix \Wallet \Test \Units \Expand ;
6+
7+ use Bavix \Wallet \Test \Infra \Factories \BuyerFactory ;
8+ use Bavix \Wallet \Test \Infra \Models \Buyer ;
9+ use Bavix \Wallet \Test \Infra \PackageModels \MyWallet ;
10+ use Bavix \Wallet \Test \Infra \TestCase ;
11+
12+ /**
13+ * @internal
14+ */
15+ final class WalletTest extends TestCase
16+ {
17+ public function testAddMethod (): void
18+ {
19+ config ([
20+ 'wallet.wallet.model ' => MyWallet::class,
21+ ]);
22+
23+ /** @var Buyer $buyer */
24+ $ buyer = BuyerFactory::new ()->create ();
25+
26+ /** @var MyWallet $wallet */
27+ $ wallet = $ buyer ->wallet ;
28+
29+ self ::assertSame ('hello world ' , $ wallet ->helloWorld ());
30+ }
31+ }
You can’t perform that action at this time.
0 commit comments