public void TableLayoutPanel_CanExtend_Control_ReturnsExpected() { var control = new ScrollableControl(); var panel = new TableLayoutPanel(); IExtenderProvider provider = panel; Assert.False(provider.CanExtend(control)); panel.Controls.Add(control); Assert.True(provider.CanExtend(control)); }
public void TableLayoutPanel_CanExtend_NotControl_ReturnsFalse(object obj) { var panel = new TableLayoutPanel(); IExtenderProvider provider = panel; Assert.False(provider.CanExtend(obj)); }
public void CanExtend_InvokeNoParent_ReturnsFalse(object extendee) { var panel = new FlowLayoutPanel(); IExtenderProvider extenderProvider = panel; Assert.False(extenderProvider.CanExtend(extendee)); }
public void FlowLayoutPanel_CanExtend_InvokeNoParent_ReturnsFalse(object extendee) { using var control = new FlowLayoutPanel(); IExtenderProvider extenderProvider = control; Assert.False(extenderProvider.CanExtend(extendee)); }
public void CanExtend_InvokeWithParent_ReturnsTrue() { var panel = new FlowLayoutPanel(); var control = new Control { Parent = panel }; IExtenderProvider extenderProvider = panel; Assert.True(extenderProvider.CanExtend(control)); }
public void FlowLayoutPanel_CanExtend_InvokeWithParent_ReturnsTrue() { using var control = new FlowLayoutPanel(); using var extendee = new Control { Parent = control }; IExtenderProvider extenderProvider = control; Assert.True(extenderProvider.CanExtend(extendee)); }