On 09/19/2009 12:29 PM, Rico Schüller wrote:
dlls/opengl32/tests/opengl.c | 10 ++++++++++ 1 files changed, 10 insertions(+), 0 deletions(-)
+ ret = wglMakeCurrent( NULL, NULL ); + ok( !ret, "wglMakeCurrent failed\n" );
shouldn't that message read "wglMakeCurrent succeeded" ?
If you are testing the last error it's usually a good idea to set the last error before the call (aka "SetLastError(0xdeadbeef)").
Am 19.09.2009 12:46, schrieb Paul Vriens:
On 09/19/2009 12:29 PM, Rico Schüller wrote:
dlls/opengl32/tests/opengl.c | 10 ++++++++++ 1 files changed, 10 insertions(+), 0 deletions(-)
- ret = wglMakeCurrent( NULL, NULL );
- ok( !ret, "wglMakeCurrent failed\n" );
shouldn't that message read "wglMakeCurrent succeeded" ?
Yes, probably something like "wglMakeCurrent succeeded, but should fail!" is really a better solution.
If you are testing the last error it's usually a good idea to set the last error before the call (aka "SetLastError(0xdeadbeef)").
I haven't called SetLastError() before, because it's not done in the rest of the tests in dlls/opengl32/tests/opengl.c . But if it is usually a good idea, I could change that, too.
On 09/19/2009 01:15 PM, Rico Schüller wrote:
Am 19.09.2009 12:46, schrieb Paul Vriens:
On 09/19/2009 12:29 PM, Rico Schüller wrote:
dlls/opengl32/tests/opengl.c | 10 ++++++++++ 1 files changed, 10 insertions(+), 0 deletions(-)
- ret = wglMakeCurrent( NULL, NULL );
- ok( !ret, "wglMakeCurrent failed\n" );
shouldn't that message read "wglMakeCurrent succeeded" ?
Yes, probably something like "wglMakeCurrent succeeded, but should fail!" is really a better solution.
If you are testing the last error it's usually a good idea to set the last error before the call (aka "SetLastError(0xdeadbeef)").
I haven't called SetLastError() before, because it's not done in the rest of the tests in dlls/opengl32/tests/opengl.c . But if it is usually a good idea, I could change that, too.
The main reason being that you don't know if the last error was set or changed unless you know what is was before.
2009/9/19 Rico Schüller kgbricola@web.de:
Yes, probably something like "wglMakeCurrent succeeded, but should fail!" is really a better solution.
For what it's worth, I think the exclamation mark might be a bit overly dramatic. It's not like e.g. your printer is on fire. :-)
On Sa, 2009-09-19 at 13:15 +0200, Rico Schüller wrote:
- ret = wglMakeCurrent( NULL, NULL );
- ok( !ret, "wglMakeCurrent failed\n" );
shouldn't that message read "wglMakeCurrent succeeded" ?
Yes, probably something like "wglMakeCurrent succeeded, but should fail!" is really a better solution
Please remenber, that all failures have the prefix: <filename>:<__LINE__>: Test failed:
My style for the ok message is to print the returned result followed by the expected result in round brackets.