public void TestRightGrid() { bool isLoaded = false; var container = new System.Windows.Controls.Grid (); var testee = new sle.Separator{ HorizontalAlignment = HorizontalAlignment.Right}; testee.Loaded += (sender, args) => isLoaded = true; EnqueueCallback(() => container.Children.Add(testee)); EnqueueCallback(() => this.Silverlight.TestSurface.Children.Add(container)); EnqueueConditional(() => isLoaded); EnqueueCallback(() => Assert.AreEqual(Orientation.Horizontal, testee.Orientation)); EnqueueTestComplete(); }
public void TestHorizontalStackPanel() { var container = new System.Windows.Controls.StackPanel { Orientation = Orientation.Horizontal }; var testee = new sle.Separator(); bool isLoaded = false; testee.Loaded += (sender, args) => isLoaded = true; EnqueueCallback(() => container.Children.Add(testee)); EnqueueCallback(() => this.Silverlight.TestSurface.Children.Add(container)); EnqueueConditional(() => isLoaded); EnqueueCallback(() => Assert.AreEqual(Orientation.Horizontal, testee.Orientation)); EnqueueTestComplete(); }