mirror of
https://github.com/ramsey/uuid.git
synced 2026-06-15 16:07:55 +03:00
Modify tests
This commit is contained in:
@@ -10,7 +10,6 @@ use Brick\Math\RoundingMode;
|
||||
use DateTimeImmutable;
|
||||
use DateTimeInterface;
|
||||
use Mockery;
|
||||
use Mockery\MockInterface;
|
||||
use PHPUnit\Framework\MockObject\MockObject;
|
||||
use Ramsey\Uuid\Builder\DefaultUuidBuilder;
|
||||
use Ramsey\Uuid\Codec\StringCodec;
|
||||
@@ -782,19 +781,6 @@ class UuidTest extends TestCase
|
||||
$this->assertSame(7, $uuid->getVersion());
|
||||
}
|
||||
|
||||
public function testUuid7ThrowsExceptionForUnsupportedFactory(): void
|
||||
{
|
||||
/** @var UuidFactoryInterface&MockInterface $factory */
|
||||
$factory = Mockery::mock(UuidFactoryInterface::class);
|
||||
|
||||
Uuid::setFactory($factory);
|
||||
|
||||
$this->expectException(UnsupportedOperationException::class);
|
||||
$this->expectExceptionMessage('The provided factory does not support the uuid7() method');
|
||||
|
||||
Uuid::uuid7();
|
||||
}
|
||||
|
||||
public function testUuid7WithDateTime(): void
|
||||
{
|
||||
$dateTime = new DateTimeImmutable('@281474976710.655');
|
||||
@@ -875,19 +861,6 @@ class UuidTest extends TestCase
|
||||
$this->assertSame(8, $uuid->getVersion());
|
||||
}
|
||||
|
||||
public function testUuid8ThrowsExceptionForUnsupportedFactory(): void
|
||||
{
|
||||
/** @var UuidFactoryInterface&MockInterface $factory */
|
||||
$factory = Mockery::mock(UuidFactoryInterface::class);
|
||||
|
||||
Uuid::setFactory($factory);
|
||||
|
||||
$this->expectException(UnsupportedOperationException::class);
|
||||
$this->expectExceptionMessage('The provided factory does not support the uuid8() method');
|
||||
|
||||
Uuid::uuid8("\x00\x11\x22\x33\x44\x55\x66\x77\x88\x99\xaa\xbb\xcc\xdd\xee\xff");
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests known version-3 UUIDs
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user