engelsystem/tests/Unit/Helpers/UuidServiceProviderTest.php

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

29 lines
750 B
PHP
Raw Normal View History

<?php
namespace Engelsystem\Test\Unit\Helpers;
use Engelsystem\Application;
use Engelsystem\Helpers\UuidServiceProvider;
use Engelsystem\Test\Unit\ServiceProviderTest;
use Illuminate\Support\Str;
class UuidServiceProviderTest extends ServiceProviderTest
{
/**
* @covers \Engelsystem\Helpers\UuidServiceProvider::register
* @covers \Engelsystem\Helpers\UuidServiceProvider::uuid
*/
public function testRegister(): void
{
$app = new Application();
$serviceProvider = new UuidServiceProvider($app);
$serviceProvider->register();
$this->assertStringMatchesFormat(
'%x%x%x%x%x%x%x%x-%x%x%x%x-4%x%x%x-%x%x%x%x-%x%x%x%x%x%x%x%x%x%x%x%x',
Str::uuid()
);
}
}