mirror of
https://github.com/reactos/reactos.git
synced 2024-10-21 00:18:26 +00:00
4230863f75
- add kmt_platform.h that includes user or kernel headers as appropriate and allows Rtl tests to run in user mode without modification - include kmt_platform.h from kmt_test.h, so that tests don't have to include separate headers. This also allows for a PCH svn path=/branches/GSoC_2011/KMTestSuite/; revision=53021
28 lines
739 B
C
28 lines
739 B
C
/*
|
|
* PROJECT: ReactOS kernel-mode tests
|
|
* LICENSE: GPLv2+ - See COPYING in the top level directory
|
|
* PURPOSE: Kernel-Mode Test Suite Runtime library memory functions test
|
|
* PROGRAMMER: Thomas Faber <thfabba@gmx.de>
|
|
*/
|
|
|
|
#define KMT_EMULATE_KERNEL
|
|
#include <kmt_test.h>
|
|
|
|
START_TEST(RtlMemory)
|
|
{
|
|
UCHAR Buffer[512];
|
|
KIRQL Irql;
|
|
int i;
|
|
|
|
KeRaiseIrql(HIGH_LEVEL, &Irql);
|
|
|
|
RtlFillMemory(Buffer, sizeof Buffer / 2, 0x55);
|
|
RtlFillMemory(Buffer + sizeof Buffer / 2, sizeof Buffer / 2, 0xAA);
|
|
for (i = 0; i < sizeof Buffer / 2; ++i)
|
|
ok_eq_uint(Buffer[i], 0x55);
|
|
for (i = sizeof Buffer / 2; i < sizeof Buffer; ++i)
|
|
ok_eq_uint(Buffer[i], 0xAA);
|
|
|
|
KeLowerIrql(Irql);
|
|
}
|