lullaby/tests/layout_system_test.cc
// Test that the LayoutSystem will SetOriginalBox and children SetDesiredSize
// in response to a ParentChangedEvent.
Test that the LayoutSystem will SetOriginalBox and children SetDesiredSize
in response to a ParentChangedEvent.
Test that the LayoutSystem will SetOriginalBox and children SetDesiredSize in response to a ParentChangedEvent .
TEST_F(QueuedLayoutSystemTest, ParentChanged) {
  const Entity parent = CreateParent();
  const Entity child = CreateChild(parent, 1.0f);
  AssertListenersEmpty();
  dispatcher_->Dispatch();
  AssertListenerMatch({ {parent, 1} }, original_boxes_);
  AssertListenerMatch({ {child, 1} }, desired_sizes_);
  AssertListenerEmpty(actual_boxes_);
}
TEST_F ( QueuedLayoutSystemTest , ParentChanged ) { const Entity parent = CreateParent ( ) ; const Entity child = CreateChild ( parent , 1.0f ) ; AssertListenersEmpty ( ) ; dispatcher_ -> Dispatch ( ) ; AssertListenerMatch ( { { parent , 1 } } , original_boxes_ ) ; AssertListenerMatch ( { { child , 1 } } , desired_sizes_ ) ; AssertListenerEmpty ( actual_boxes_ ) ; }
Test that the LayoutSystem will SetOriginalBox and children SetDesiredSize
in response to a ParentChangedEvent.
Test that the LayoutSystem will SetOriginalBox and children SetDesiredSize in response to a ParentChangedEvent .