[NTOSKRNL] Add a test for ExUuidCreate

This commit is contained in:
Pierre Schweitzer 2019-03-02 10:29:26 +01:00
parent 28309096df
commit bbfb3caa36
No known key found for this signature in database
GPG key ID: 7545556C3D585B0B
3 changed files with 24 additions and 0 deletions

View file

@ -54,6 +54,7 @@ list(APPEND KMTEST_DRV_SOURCE
ntos_ex/ExSequencedList.c
ntos_ex/ExSingleList.c
ntos_ex/ExTimer.c
ntos_ex/ExUuid.c
ntos_fsrtl/FsRtlDissect.c
ntos_fsrtl/FsRtlExpression.c
ntos_fsrtl/FsRtlLegal.c

View file

@ -19,6 +19,7 @@ KMT_TESTFUNC Test_ExResource;
KMT_TESTFUNC Test_ExSequencedList;
KMT_TESTFUNC Test_ExSingleList;
KMT_TESTFUNC Test_ExTimer;
KMT_TESTFUNC Test_ExUuid;
KMT_TESTFUNC Test_FsRtlDissect;
KMT_TESTFUNC Test_FsRtlExpression;
KMT_TESTFUNC Test_FsRtlLegal;
@ -90,6 +91,7 @@ const KMT_TEST TestList[] =
{ "ExSequencedList", Test_ExSequencedList },
{ "ExSingleList", Test_ExSingleList },
{ "-ExTimer", Test_ExTimer },
{ "ExUuid", Test_ExUuid },
{ "Example", Test_Example },
{ "FsRtlDissect", Test_FsRtlDissect },
{ "FsRtlExpression", Test_FsRtlExpression },

View file

@ -0,0 +1,21 @@
/*
* PROJECT: ReactOS kernel-mode tests
* LICENSE: LGPLv2+ - See COPYING.LIB in the top level directory
* PURPOSE: Kernel-Mode Test Suite UUIDs test
* PROGRAMMER: Pierre Schweitzer <pierre@reactos.org>
*/
#include <kmt_test.h>
#define NDEBUG
#include <debug.h>
START_TEST(ExUuid)
{
UUID Uuid;
NTSTATUS Status;
Status = ExUuidCreate(&Uuid);
ok(Status == STATUS_SUCCESS, "ExUuidCreate returned unexpected status: %lx\n", Status);
ok((Uuid.Data3 & 0x1000) == 0x1000, "Invalid UUID version: %x\n", (Uuid.Data3 & 0xF000));
}