first commit
This commit is contained in:
5
tests/Unit/ExampleTest.php
Normal file
5
tests/Unit/ExampleTest.php
Normal file
@@ -0,0 +1,5 @@
|
||||
<?php
|
||||
|
||||
test('that true is true', function () {
|
||||
expect(true)->toBeTrue();
|
||||
});
|
||||
14
tests/Unit/MedicalReportTemplateWorkbookTest.php
Normal file
14
tests/Unit/MedicalReportTemplateWorkbookTest.php
Normal file
@@ -0,0 +1,14 @@
|
||||
<?php
|
||||
|
||||
use App\Support\MedicalReport\TemplateWorkbook;
|
||||
|
||||
test('template workbook groups fields by departments', function () {
|
||||
/** @var TemplateWorkbook $templateWorkbook */
|
||||
$templateWorkbook = app(TemplateWorkbook::class);
|
||||
|
||||
$departments = $templateWorkbook->departments();
|
||||
|
||||
expect($departments)->not->toBeEmpty();
|
||||
expect(collect($departments)->pluck('name'))->toContain('Рентгенологическое отделение');
|
||||
expect(collect($departments)->every(fn (array $department): bool => ! empty($department['sources'] ?? [])))->toBeTrue();
|
||||
});
|
||||
Reference in New Issue
Block a user