Skip to content

Commit

Permalink
Fix CS
Browse files Browse the repository at this point in the history
  • Loading branch information
fabpot committed Jul 20, 2022
1 parent 2b52d90 commit 2120eba
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Command/InspectUlidCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
['toBase58', $ulid->toBase58()],
['toRfc4122', $ulid->toRfc4122()],
new TableSeparator(),
['Time', ($ulid->getDateTime())->format('Y-m-d H:i:s.v \U\T\C')],
['Time', $ulid->getDateTime()->format('Y-m-d H:i:s.v \U\T\C')],
]);

return 0;
Expand Down
2 changes: 1 addition & 1 deletion Tests/Command/InspectUuidCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public function testNil()
EOF
, $commandTester->getDisplay(true));
, $commandTester->getDisplay(true));
}

public function testUnknown()
Expand Down
2 changes: 1 addition & 1 deletion Tests/Factory/UlidFactoryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public function testCreate()
$this->assertSame('999999.123000', $ulid2->getDateTime()->format('U.u'));

$this->assertFalse($ulid1->equals($ulid2));
$this->assertSame(-1, ($ulid1->compare($ulid2)));
$this->assertSame(-1, $ulid1->compare($ulid2));

$ulid3 = $ulidFactory->create(new \DateTime('@1234.162524'));
$this->assertSame('1234.162000', $ulid3->getDateTime()->format('U.u'));
Expand Down
8 changes: 4 additions & 4 deletions Tests/UuidTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -320,13 +320,13 @@ public function testFromStringOnExtendedClassReturnsStatic()

public function testGetDateTime()
{
$this->assertEquals(\DateTimeImmutable::createFromFormat('U.u', '103072857660.684697'), ((new UuidV1('ffffffff-ffff-1fff-a456-426655440000'))->getDateTime()));
$this->assertEquals(\DateTimeImmutable::createFromFormat('U.u', '0.000001'), ((new UuidV1('1381400a-1dd2-11b2-a456-426655440000'))->getDateTime()));
$this->assertEquals(\DateTimeImmutable::createFromFormat('U.u', '103072857660.684697'), (new UuidV1('ffffffff-ffff-1fff-a456-426655440000'))->getDateTime());
$this->assertEquals(\DateTimeImmutable::createFromFormat('U.u', '0.000001'), (new UuidV1('1381400a-1dd2-11b2-a456-426655440000'))->getDateTime());
$this->assertEquals(new \DateTimeImmutable('@0'), (new UuidV1('13814001-1dd2-11b2-a456-426655440000'))->getDateTime());
$this->assertEquals(new \DateTimeImmutable('@0'), (new UuidV1('13814000-1dd2-11b2-a456-426655440000'))->getDateTime());
$this->assertEquals(new \DateTimeImmutable('@0'), (new UuidV1('13813fff-1dd2-11b2-a456-426655440000'))->getDateTime());
$this->assertEquals(\DateTimeImmutable::createFromFormat('U.u', '-0.000001'), ((new UuidV1('13813ff6-1dd2-11b2-a456-426655440000'))->getDateTime()));
$this->assertEquals(new \DateTimeImmutable('@-12219292800'), ((new UuidV1('00000000-0000-1000-a456-426655440000'))->getDateTime()));
$this->assertEquals(\DateTimeImmutable::createFromFormat('U.u', '-0.000001'), (new UuidV1('13813ff6-1dd2-11b2-a456-426655440000'))->getDateTime());
$this->assertEquals(new \DateTimeImmutable('@-12219292800'), (new UuidV1('00000000-0000-1000-a456-426655440000'))->getDateTime());
}

public function testFromStringBase58Padding()
Expand Down

0 comments on commit 2120eba

Please sign in to comment.