problem with unittests for animated zooming

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

problem with unittests for animated zooming

Emanuel Schütze

I try to write unittests for my animated zooming code [1] and I get a problem:

I think, the problem is that I want to test asyncronous code, because the
animations of zooming and panning runs by call "window.setInterval(..)".
So, f.e. the call "map.zoomIn()" doesn't work and the unittest runs fail (good
example is test_Map.html; you can run it here [2] ).
If I turn the animation off by calling "map.zoomIn(false)" the test is ok!

Now, I tried it with:
t.wait_result ([seconds])


t.delay_call ([seconds], function(){ map.zoomIn(); }).

But both doesn't work!

Can you help me?


Dev mailing list
[hidden email]