- Add unloading ability.

- Don't forget to wrap any testing module into StartTest / FinishTest.

svn path=/trunk/; revision=34951
This commit is contained in:
Aleksey Bragin 2008-07-30 11:11:25 +00:00
parent 52d04e432e
commit c6d5d68953
2 changed files with 19 additions and 0 deletions

View file

@ -108,6 +108,16 @@ VOID NtoskrnlObTest();
VOID NtoskrnlExecutiveTests(); VOID NtoskrnlExecutiveTests();
VOID NtoskrnlPoolsTest(); VOID NtoskrnlPoolsTest();
/*
* KmtestUnload
*/
VOID
NTAPI
KmtestUnload(IN PDRIVER_OBJECT DriverObject)
{
/* Nothing to do here */
}
/* /*
* DriverEntry * DriverEntry
*/ */
@ -117,6 +127,11 @@ DriverEntry(PDRIVER_OBJECT DriverObject,
PUNICODE_STRING RegistryPath) PUNICODE_STRING RegistryPath)
{ {
DbgPrint("\n===============================================\nKernel Mode Regression Test driver starting...\n"); DbgPrint("\n===============================================\nKernel Mode Regression Test driver starting...\n");
/* Set necessary routines */
DriverObject->DriverUnload = KmtestUnload;
//NtoskrnlExecutiveTests(); //NtoskrnlExecutiveTests();
//NtoskrnlIoDeviceInterface(); //NtoskrnlIoDeviceInterface();
NtoskrnlIoTests(); NtoskrnlIoTests();

View file

@ -89,6 +89,8 @@ VOID NtoskrnlIoIrpTest()
USHORT size; USHORT size;
IRP *iorp; IRP *iorp;
StartTest();
// 1st test // 1st test
size = sizeof(IRP) + 5 * sizeof(IO_STACK_LOCATION); size = sizeof(IRP) + 5 * sizeof(IO_STACK_LOCATION);
iorp = ExAllocatePool(NonPagedPool, size); iorp = ExAllocatePool(NonPagedPool, size);
@ -163,6 +165,8 @@ VOID NtoskrnlIoIrpTest()
IoFreeIrp(iorp); IoFreeIrp(iorp);
} }
FinishTest("NTOSKRNL Io Irp");
} }
VOID NtoskrnlIoTests() VOID NtoskrnlIoTests()