| 12345678910111213141516171819202122232425262728293031323334353637 |
- <?php
- namespace Tests\Services\BatchService;
- use App\Services\BatchService;
- use Tests\TestCase;
- use App\Batch;
- use App\Traits\TestMockSubServices;
- class AssignTasksTest extends TestCase
- {
- use TestMockSubServices;
- /** @var BatchService $service */
- public $service;
- private $data;
- private $amount=2;
- function setUp(): void
- {
- parent::setUp();
- $this->service = app('BatchService');
- $this->data['Batses']
- = factory(Batch::class, $this->amount)
- ->create();
- }
- public function testReturned()
- {
- $this->assertTrue(true);
- }
- function tearDown(): void
- {
- Batch::query()
- ->whereIn('id',data_get($this->data['Batses'],'*.id')??[])
- ->delete();
- parent::tearDown();
- }
- }
|