http/tests/misc/slow-loading-animated-image.html fails very often on iOS Simulator, especially in debug:
The animated GIF used by this tests has 48 frames. Frames (1-47) have frame-length=20ms. Frame 48 has frame-length=10s. The test relies on capturing the 48th frame which should be shown after 47*20=940ms. On the mac ports, setTimeout for 1 second was enough to ensure the 48th frame is displayed at the time the test ends. For iOS, 1 second was not enough, so I had to increase the setTimeout from 1 second to 1500ms. This seems to be not enough all the times. I checked the flakiness dashboard and I found out the number of frames, which were animated after 1500ms, was: 16, 17, 20, 22, 23, 47. So increasing the setTimeout seems not an option. We have to wait at least 4500ms to ensure the first 47 frames were already rendered and the 48th frame is displayed.
Other possible ways to fix this are the following:
1. Skip the test for iOS.
2. Add an internal API which returns the number of frames of an animated image and compare it with the actual number of frames the image has which is 48 for this test.
> 2. Add an internal API which returns the number of frames of an animated image and compare it with the actual number of frames the image has which is 48 for this test.
This definitely sounds better than skipping.
Said, do you expect to work on this soon? The test fails on bots very frequently.
Marked test as flaky in <http://trac.webkit.org/projects/webkit/changeset/201731>