• Ian Hickson's avatar
    Make tests more realistic (#5762) · 5bc8888e
    Ian Hickson authored
    Previously, pumpWidget() would do a partial pump (it didn't trigger
    Ticker callbacks or post-frame callbacks), and pump() would do a full
    pump. This patch brings them closer together. It also makes runApp run a
    full actual frame, rather than skipping the transient callback part of
    the frame logic. Having "half-frames" in the system was confusing and
    could lead to bugs where code expecting to run before the next layout
    pass didn't because a "half-frame" ran first.
    
    Also, make Tickers start ticking in the frame that they were started in,
    if they were started during a frame. This means we no longer spin a
    frame for t=0, we jump straight to the first actual frame.
    
    Other changes in this patch:
    
    * rename WidgetsBinding._runApp to WidgetsBinding.attachRootWidget, so
      that tests can use it to more accurately mock out runApp.
    
    * allow loadStructuredData to return synchronously.
    
    * make handleBeginFrame handle not being given a time stamp.
    
    * make DataPipeImageProvider.loadAsync protected (rather than private),
      and document it. There wasn't really a reason for it to be private.
    
    * fix ImageConfiguration.toString.
    
    * introduce debugPrintBuildScope and debugPrintScheduleBuildForStacks,
      which can help debug problems with widgets getting marked as dirty but
      not cleaned.
    
    * make debugPrintRebuildDirtyWidgets say "Building" the first time and
      "Rebuilding" the second, to make it clearer when a widget is first
      created. This makes debugging widget lifecycle issues much easier.
    
    * make debugDumpApp more resilient.
    
    * debugPrintStack now takes a label that is printed before the stack.
    
    * improve the banner shown for debugPrintBeginFrameBanner.
    
    * various and sundry documentation fixes
    5bc8888e
Name
Last commit
Last update
..
animated_cross_fade.dart Loading commit data...
animated_size.dart Loading commit data...
app.dart Loading commit data...
auto_layout.dart Loading commit data...
banner.dart Loading commit data...
basic.dart Loading commit data...
binding.dart Loading commit data...
child_view.dart Loading commit data...
clamp_overscrolls.dart Loading commit data...
container.dart Loading commit data...
debug.dart Loading commit data...
dismissable.dart Loading commit data...
drag_target.dart Loading commit data...
editable.dart Loading commit data...
focus.dart Loading commit data...
form.dart Loading commit data...
framework.dart Loading commit data...
gesture_detector.dart Loading commit data...
gridpaper.dart Loading commit data...
heroes.dart Loading commit data...
image.dart Loading commit data...
implicit_animations.dart Loading commit data...
layout_builder.dart Loading commit data...
lazy_block.dart Loading commit data...
locale_query.dart Loading commit data...
media_query.dart Loading commit data...
mimic.dart Loading commit data...
modal_barrier.dart Loading commit data...
navigator.dart Loading commit data...
notification_listener.dart Loading commit data...
overlay.dart Loading commit data...
page_storage.dart Loading commit data...
pageable_list.dart Loading commit data...
pages.dart Loading commit data...
performance_overlay.dart Loading commit data...
placeholder.dart Loading commit data...
raw_keyboard_listener.dart Loading commit data...
routes.dart Loading commit data...
scroll_behavior.dart Loading commit data...
scroll_configuration.dart Loading commit data...
scrollable.dart Loading commit data...
scrollable_grid.dart Loading commit data...
scrollable_list.dart Loading commit data...
semantics_debugger.dart Loading commit data...
size_changed_layout_notifier.dart Loading commit data...
status_transitions.dart Loading commit data...
table.dart Loading commit data...
text_selection.dart Loading commit data...
title.dart Loading commit data...
transitions.dart Loading commit data...
unique_widget.dart Loading commit data...
virtual_viewport.dart Loading commit data...