Files
brandon schaefer b6c4245d86 Always open around creating GUID
#rb ben.clayton

[CL 35427217 by brandon schaefer in ue5-main branch]
2024-08-09 12:40:04 -04:00

20 lines
512 B
C++

// Copyright Epic Games, Inc. All Rights Reserved.
#include "Catch2Includes.h"
#include "AutoRTFM/AutoRTFM.h"
#include "HAL/PlatformMisc.h"
TEST_CASE("FPlatformMisc.CreateGUID")
{
AutoRTFM::ForTheRuntime::SetEnsureOnAbortByLanguage(true);
FGuid Guid;
AutoRTFM::ETransactionResult Result = AutoRTFM::Transact([&]
{
FPlatformMisc::CreateGuid(Guid);
});
AutoRTFM::ForTheRuntime::SetEnsureOnAbortByLanguage(false);
REQUIRE(AutoRTFM::ETransactionResult::Committed == Result);
REQUIRE(Guid != FGuid());
}