1
0
Fork 0

test creating v4 uuid

This commit is contained in:
Kevin Matz 2021-08-22 16:01:46 -04:00
parent 9d5c985254
commit 026a4a16de
1 changed files with 11 additions and 0 deletions

View File

@ -39,3 +39,14 @@ TEST(UUID, ver4fromString)
ASSERT_EQ(uuid.string(), str);
}
TEST(UUID, createV4)
{
auto uuid = UUID::uuid();
uuid.uuid4();
ASSERT_EQ(uuid.type(), UUID::RFC4122);
ASSERT_EQ(uuid.version(), 4);
ASSERT_EQ(uuid, UUID::uuid(uuid.string()));
}