W->A calls

James Hawkins truiken at gmail.com
Tue Aug 31 10:11:02 CDT 2004


> However, I don't know how to make simple tests.. as I'd really need to
> test wether the code I write works, and works properly :p

The best way to test the functionality of a certain api function
against windows is to read the msdn docs on that function.  There are
certain easy things to check like the error codes that are either
returned or set using SetLastError (and are read using GetLastError.) 
The docs will also tell you pretty precisely what the function should
and should not do, and you write the tests to make sure that the
functions do what they're supposed to do.  A lot of the times, msdn
docs will have example code and will usually show the expected output
(when necessary.)  You can test against this output to see if the
results are the same.  Some api's cant really be tested with wine's
testing system because the effects may be visual etc, so the way to
test that is to run the program and see if the visual change coincides
with the way the program runs in windows.  If you dont have a windows
install to run the program from, I'm sure that someone on wine-devel
can run the program for you.

On Tue, 31 Aug 2004 11:10:57 +0200, Joris Huizer <jorishuizer at planet.nl> wrote:
> Hello,
> 
> By accident, I removed the emails of the thread I started, but I'll look
>   it up if necessary;
> I found this old wine issue of some time ago.. I think the patch it has
> there could be helpfull
> 
> http://winehq.org/?issue=229#About%20Converting%20W-%3EA%20Calls
> 
> However, I don't know how to make simple tests.. as I'd really need to
> test wether the code I write works, and works properly :p
> 
> How do I write tests for that? I'm running linux (in practice, I never
> boot into windows) so how should I do this (testing without windows
> environment)? How are tests supposed to run?
> 
> I hope you can give some clues on that; I found there are many W->A
> calls in dlls/winmm/winmm.c (according to the janitorial page) so I
> might start there (hoping not all of them are so tricky ;) )
> 
> Thanks for suggestions on this,
> 
> Joris
> 
> 


-- 
James Hawkins



More information about the wine-devel mailing list