-
Notifications
You must be signed in to change notification settings - Fork 69
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[golden_toolkit] Goldens for different devices have different time advance #146
Comments
the device setup function runs in between resizing for each device. So in this case, 50ms are pumped before Device.phone, 100ms are pumped before iphone11, and 150ms are pumped before the tablet landscape golden. In other words, what you are seeing is working as intended. if your deviceSetup function does not advance time, I would expect all of the screen variations to be in the same state. |
if I leave deviceSetup empty and put the pump in customPump the result will be the same:
|
I think the customPump (I HATE that name) will similarly be called in between each golden as well. What are you trying to do, are you trying to pump 50ms and THEN capture a golden for multiple devices? If so, just move your |
or you could do something like:
|
I need to rid from any pumps between each golden. If I leave |
the error:
For easy access I made a repository https://github.com/cyrax111/golden_test |
I'll try to look at it today. I suspect you will still need a pump, but with Duration(milliseconds: 0) |
Thank you! I think one pump without duration don't help me unfortunately as well. |
@coreysprague you can try this https://github.com/cyrax111/golden_test/tree/v2 |
@cyrax111 -- sorry for the delay. Been slammed at work |
@coreysprague thank you for your answer!! |
I think I need a little bit another behavior. I want to separate devices in order to make them independent. I added this feature here https://github.com/cyrax111/golden_test/tree/v3. If you want I can make PR. |
I made a simple project just entered :
flutter create golden
and added FutureBuilder
The behavior is the first 150 milliseconds is showed CircularProgressIndicator then an orange container.
I wrote follow golden test:
and have got follow result:
Device.phone
Device.iphone11
Device.tabletLandscape
Despite only one
tester.pump
I have different time advances.I expected the same picture on all devices like on Device.phone.
The text was updated successfully, but these errors were encountered: