Eh, this does not seem like a proper way to get a unit test to pass.
Sleep()... that leads to the dark side! :-)
Why does it need a Sleep()? If its failing on Wine, then shouldn't it be fixed in the libs? And if its on orig-winxp-vista then there must be a better way to wait? Or no?
The string "This makes the tests pass on my pc" isn't very good either. What system?
In general, introducing magic Sleep() values in code is not a good idea. If the test system is stressed, you will start getting failures again = bad idea.
/p
On Wed, 2008-02-13 at 02:26 +0100, Stefan Dösinger wrote:
Am Mittwoch, 13. Februar 2008 02:25:30 schrieb Maarten Lankhorst:
This makes the tests pass on my pc.
d3d8 might need it as well
On Wednesday 13 February 2008 03:11:24 Peter Dons Tychsen wrote:
The string "This makes the tests pass on my pc" isn't very good either. What system?
Given that the default mode for the tests in the last years has been "Needs to pass on Alexandre's system", I don't think it's that bad. ;)
Cheeers, Kai
Am Mittwoch, 13. Februar 2008 03:11:24 schrieb Peter Dons Tychsen:
Eh, this does not seem like a proper way to get a unit test to pass.
Sleep()... that leads to the dark side! :-)
I talked to Maarten on IRC about this. The problem seems to be that his monitor takes ages to mode switch, but ChangeDisplaySettings returns before this modeswitch is done. Also the opengl driver attempts to draw before the setup is ready, which fails and causes the test failures.
So it sounds like a driver bug which will only affect the tests(since games draw repeatedly and do not care if the first few frames do not render properly)