initial: bootstrap from BukidBountyApp base
This commit is contained in:
15
tests/helpers.php
Normal file
15
tests/helpers.php
Normal file
@@ -0,0 +1,15 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use Hyperf\Testing\ModelFactory;
|
||||
use Hypervel\Context\ApplicationContext;
|
||||
|
||||
if (! function_exists('factory')) {
|
||||
function factory(string $class, mixed ...$arguments)
|
||||
{
|
||||
return ApplicationContext::getContainer()
|
||||
->get(ModelFactory::class)
|
||||
->factory($class, ...$arguments);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user