MCPcopy Create free account
hub / github.com/EndstoneMC/endstone / TEST

Function TEST

tests/test_uuid.cpp:22–35  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

20#include "endstone/core/util/uuid.h"
21
22TEST(UUIDTest, ConvertToAndFromEndstone)
23{
24 endstone::UUID expect;
25 for (std::uint8_t i = 0; i < 16; ++i) {
26 expect.data[i] = i; // Initialization for test
27 }
28
29 const auto mce_uuid = endstone::core::EndstoneUUID::toMinecraft(expect);
30 const auto actual = endstone::core::EndstoneUUID::fromMinecraft(mce_uuid);
31
32 for (std::uint8_t i = 0; i < 16; ++i) {
33 EXPECT_EQ(expect.data[i], actual.data[i]);
34 }
35}

Callers

nothing calls this directly

Calls 2

toMinecraftFunction · 0.85
fromMinecraftFunction · 0.85

Tested by

no test coverage detected