ntdll/tests: Mark the NtReadFile call which doesn't return STATUS_PENDING for an overlapped IO call as broken, and don't test returned values in broken case.
This commit is contained in:
parent
49e31d29ca
commit
8eb9ffb3fa
|
@ -781,6 +781,8 @@ static void read_file_test(void)
|
||||||
iosb.Information = 0xdeadbeef;
|
iosb.Information = 0xdeadbeef;
|
||||||
offset.QuadPart = strlen(text) + 2;
|
offset.QuadPart = strlen(text) + 2;
|
||||||
status = pNtReadFile( handle, event, apc, &apc_count, &iosb, buffer, 2, &offset, NULL );
|
status = pNtReadFile( handle, event, apc, &apc_count, &iosb, buffer, 2, &offset, NULL );
|
||||||
|
todo_wine
|
||||||
|
ok(status == STATUS_PENDING || broken(status == STATUS_END_OF_FILE) /* before Vista */, "expected STATUS_PENDING, got %#x\n", status);
|
||||||
if (status == STATUS_PENDING) /* vista */
|
if (status == STATUS_PENDING) /* vista */
|
||||||
{
|
{
|
||||||
WaitForSingleObject( event, 1000 );
|
WaitForSingleObject( event, 1000 );
|
||||||
|
@ -791,16 +793,6 @@ static void read_file_test(void)
|
||||||
SleepEx( 1, TRUE ); /* alertable sleep */
|
SleepEx( 1, TRUE ); /* alertable sleep */
|
||||||
ok( apc_count == 1, "apc was not called\n" );
|
ok( apc_count == 1, "apc was not called\n" );
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
ok( status == STATUS_END_OF_FILE, "wrong status %x\n", status );
|
|
||||||
ok( U(iosb).Status == 0xdeadbabe, "wrong status %x\n", U(iosb).Status );
|
|
||||||
ok( iosb.Information == 0xdeadbeef, "wrong info %lu\n", iosb.Information );
|
|
||||||
ok( !is_signaled( event ), "event is signaled\n" );
|
|
||||||
ok( !apc_count, "apc was called\n" );
|
|
||||||
SleepEx( 1, TRUE ); /* alertable sleep */
|
|
||||||
ok( !apc_count, "apc was called\n" );
|
|
||||||
}
|
|
||||||
CloseHandle( handle );
|
CloseHandle( handle );
|
||||||
|
|
||||||
/* now a non-overlapped file */
|
/* now a non-overlapped file */
|
||||||
|
|
Loading…
Reference in New Issue