kernel32: add more tests for FormatMessage{A,W}

2009-10-28 Thread Louis Lenders
>FormatMessage uses the same backend to find the requested resource as >FindResource does, so I'd guess that they both fail in the same way >when a resource id or a language does not exist in the module. I still fail to see how I can call FindResource for a missing message-id. In the end they

Re: kernel32: add more tests for FormatMessage{A,W}

2009-10-28 Thread Dmitry Timoshkov
"Louis Lenders" wrote: FormatMessage uses the same backend to find the requested resource as FindResource does, so I'd guess that they both fail in the same way when a resource id or a language does not exist in the module. Parsing an actual resource data is not necessary. ok, but isn't that

kernel32: add more tests for FormatMessage{A,W}

2009-10-28 Thread Louis Lenders
>FormatMessage uses the same backend to find the requested resource as >FindResource does, so I'd guess that they both fail in the same way >when a resource id or a language does not exist in the module. Parsing >an actual resource data is not necessary. ok, but isn't that test already in tests/r

Re: kernel32: add more tests for FormatMessage{A,W}

2009-10-28 Thread Dmitry Timoshkov
"Louis Lenders" wrote: 1. There is no point in testing last error if an API didn't fail Couldn't it be that the API sets ERROR_SUCCES if it doesn't fail? That's unusual, there are APIs that do that, but they are exceptions, and it's worth to test (and fix) it only if there is an app that de

kernel32: add more tests for FormatMessage{A,W}

2009-10-28 Thread Louis Lenders
>A couple of suggestions: >1. There is no point in testing last error if an API didn't fail Couldn't it be that the API sets ERROR_SUCCES if it doesn't fail? >2. It would be helpful to simultaneously test return values and >last error for FindResource, which should have similar behaviour >(and

Re: kernel32: add more tests for FormatMessage{A,W}

2009-10-26 Thread Dmitry Timoshkov
"Louis Lenders" wrote: The attached tests show that this is true for "non-special" language-id's, but not for the special ones: (LANG_NEUTRAL, SUBLANG_NEUTRAL), (LANG_NEUTRAL, SUBLANG_DEFAULT),(LANG_NEUTRAL, SUBLANG_SYS_DEFAULT), and (DWORD)MAKELANGID(LANG_ENGLISH, SUBLANG_ENGLISH_US) In the l