I'm trying to do a widget test in flutter to one widget which uses WidgetsBinding.instance.addPostFrameCallback() to show a dialog at the very beggining of the widget lifecycle.
The widget works fine, but I cannot figure out how to do a widget test, because the very first expect() of the test is executed before this post frame is triggered.
Anyway to "tell" the test to wait until all the post frames are dispatched?
PD: tester.pump(), tester.pumpAndSettle(), etc. are not working.