e52de71408
It is unclear if this will help reduce flakiness and timeouts. Until now the test was setting the listener and making the transition on the same microtask. If the transition were to complete before the listener is fully set up, then that would explain the timeout: the transition event is never fired at that point. Honestly, I find this scenario hard to believe, but regardless it is worth a try. This small refactor changes the order to ensure the listener is set up upfront, and only later we initiate the transition. Change-Id: I3ae2bfae210ef307935c3d7f2aec9af82df1ddd9 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/332625 Commit-Queue: Sigmund Cherem <sigmund@google.com> Reviewed-by: Srujan Gaddam <srujzs@google.com>