As part of the BuildFaster project (see https://wiki.mozilla.org/ReleaseEngineering/BuildFaster), we are investigating whether certain slow mochitests can be sped up.
test_resize_move_windows.html is a slow test, average execution time on a recent run (in ms):
Mounir, as the original test author, would you be willing to help investigate whether this test can be sped up?
One of the issue with this test is that we test (among other things) some things that should not happen and that is handled by the native window implementation. In other words, we can't just count how many times we went into the event loop and know it should have happen. For the moment, there is a hard-coded constant of 10 times into the event loop. I can lower this to 5 or 4 but it might leads to random-green or weird failures. The former are not a major issue and the later will be visible soon if they should happen.
I can hardly do anything else, this test will remain a bit slow. Actually, I could do all the changes that shouldn't create any change in the window and wait after all of them being called instead of after each change but I would prefer to avoid that...
Created attachment 547766 [details] [diff] [review]
I did actually change my mind and went to this configuration:
- do all changes;
- hit the event loop 5 times to see if something happens.
The result is that, locally, the test was taking 2m45s and is now taking 14s. The only major issue is that if the test someday fails a dev will have to manually check which operation was accepted. It is worth it I think.
Comment on attachment 547766 [details] [diff] [review]
Sounds like a good tradeoff!