diff --git a/rostests/winetests/kernel32/virtual.c b/rostests/winetests/kernel32/virtual.c index 95f4f18653a..e9582712022 100755 --- a/rostests/winetests/kernel32/virtual.c +++ b/rostests/winetests/kernel32/virtual.c @@ -298,8 +298,8 @@ static void test_VirtualAlloc(void) memset( addr1, 0x55, 20 ); ok( *(DWORD *)addr1 == 0x55555555, "wrong data %x\n", *(DWORD *)addr1 ); - skip("MEM_RESET is not currently supported\n"); -#if 0 +if(winetest_interactive) +{ addr2 = VirtualAlloc( addr1, 0x1000, MEM_RESET, PAGE_NOACCESS ); ok( addr2 == addr1 || broken( !addr2 && GetLastError() == ERROR_INVALID_PARAMETER), /* win9x */ "VirtualAlloc failed err %u\n", GetLastError() ); @@ -325,7 +325,10 @@ static void test_VirtualAlloc(void) ok( !addr2, "VirtualAlloc failed\n" ); ok( GetLastError() == ERROR_INVALID_ADDRESS, "wrong error %u\n", GetLastError() ); } -#endif +} +else + skip("MEM_RESET is not currently supported\n"); + /* invalid protection values */ SetLastError(0xdeadbeef); addr2 = VirtualAlloc(NULL, 0x1000, MEM_RESERVE, 0); @@ -742,8 +745,8 @@ static void test_MapViewOfFile(void) ok(info.Type == MEM_MAPPED, "Type should have been MEM_MAPPED instead of 0x%x\n", info.Type); } - skip("MEM_RESET is not currently supported\n"); -#if 0 +if(winetest_interactive) +{ addr = VirtualAlloc( ptr, MAPPING_SIZE, MEM_RESET, PAGE_READONLY ); ok( addr == ptr || broken(!addr && GetLastError() == ERROR_INVALID_PARAMETER), /* win9x */ "VirtualAlloc failed with error %u\n", GetLastError() ); @@ -752,7 +755,9 @@ static void test_MapViewOfFile(void) ok( !ret || broken(ret) /* win9x */, "VirtualFree succeeded\n" ); if (!ret) ok( GetLastError() == ERROR_INVALID_PARAMETER, "VirtualFree failed with %u\n", GetLastError() ); -#endif +} +else + skip("MEM_RESET is not currently supported\n"); ret = UnmapViewOfFile(ptr2); ok(ret, "UnmapViewOfFile failed with error %d\n", GetLastError()); @@ -1089,8 +1094,6 @@ static void test_IsBadCodePtr(void) static void test_write_watch(void) { - skip("test_write_watch - MEM_WRITE_WATCH is currently not supported\n"); -#if 0 char *base; DWORD ret, size, old_prot; MEMORY_BASIC_INFORMATION info; @@ -1387,7 +1390,6 @@ static void test_write_watch(void) if (count) ok( results[0] == base + 5*pagesize, "wrong result %p\n", results[0] ); VirtualFree( base, 0, MEM_FREE ); -#endif } START_TEST(virtual) @@ -1435,5 +1437,8 @@ START_TEST(virtual) test_IsBadReadPtr(); test_IsBadWritePtr(); test_IsBadCodePtr(); - test_write_watch(); + if(winetest_interactive) + test_write_watch(); + else + skip("test_write_watch - MEM_WRITE_WATCH is currently not supported\n"); }