Example #1
0
 public void CanBeParentedToTest()
 {
     using TestControlDesigner controlDesigner = new TestControlDesigner();
     using Button button = new Button();
     controlDesigner.Initialize(button);
     Assert.True(controlDesigner.CanBeParentedTo(new ParentControlDesigner()));
 }
Example #2
0
 public void InheritanceAttributeProperty()
 {
     using TestControlDesigner controlDesigner = new TestControlDesigner();
     using Button button = new Button();
     controlDesigner.Initialize(button);
     Assert.NotNull(controlDesigner.GetInheritanceAttributeProperty());
 }
Example #3
0
 public void OnCreateHandleTest()
 {
     using TestControlDesigner controlDesigner = new TestControlDesigner();
     using Button button = new Button();
     controlDesigner.Initialize(button);
     controlDesigner.OnCreateHandleMethod();
 }
Example #4
0
 public void HookChildControlsTest()
 {
     using TestControlDesigner controlDesigner = new TestControlDesigner();
     using Button button = new Button();
     controlDesigner.Initialize(button);
     controlDesigner.HookChildControlsMethod(new Control());
 }
Example #5
0
        public void CanBeParentedToTest()
        {
            TestControlDesigner controlDesigner = new TestControlDesigner();

            Assert.NotNull(controlDesigner);
            controlDesigner.Initialize(new Button());
            Assert.True(controlDesigner.CanBeParentedTo(new ParentControlDesigner()));
        }
Example #6
0
        public void OnSetComponentDefaultsTest()
        {
            using TestControlDesigner controlDesigner = new TestControlDesigner();
            using Button button = new Button();
            controlDesigner.Initialize(button);
#pragma warning disable CS0618 // Type or member is obsolete
            controlDesigner.OnSetComponentDefaults();
#pragma warning restore CS0618
        }
Example #7
0
        public void InitializeTest()
        {
            TestControlDesigner controlDesigner = new TestControlDesigner();

            try
            {
                controlDesigner.Initialize(new Button());
            }
            catch (Exception ex)
            {
                Assert.True(false, "Expected no exception, but got: " + ex.Message);
            }
        }
Example #8
0
        public void OnCreateHandleTest()
        {
            TestControlDesigner controlDesigner = new TestControlDesigner();

            Assert.NotNull(controlDesigner);
            controlDesigner.Initialize(new Button());
            try
            {
                controlDesigner.OnCreateHandleMethod();
            }
            catch (Exception ex)
            {
                Assert.True(false, "Expected no exception, but got: " + ex.Message);
            }
        }
Example #9
0
        public void HookChildControlsTest()
        {
            TestControlDesigner controlDesigner = new TestControlDesigner();

            Assert.NotNull(controlDesigner);
            controlDesigner.Initialize(new Button());
            try
            {
                controlDesigner.HookChildControlsMethod(new Control());
            }
            catch (Exception ex)
            {
                Assert.True(false, "Expected no exception, but got: " + ex.Message);
            }
        }
Example #10
0
        public void OnSetComponentDefaultsTest()
        {
            TestControlDesigner controlDesigner = new TestControlDesigner();

#pragma warning disable 618
            Assert.NotNull(controlDesigner);
            controlDesigner.Initialize(new Button());
            try
            {
                controlDesigner.OnSetComponentDefaults();
            }
            catch (Exception ex)
            {
                Assert.True(false, "Expected no exception, but got: " + ex.Message);
            }
#pragma warning restore 618
        }
Example #11
0
 public void InitializeNewComponentTest()
 {
     using TestControlDesigner controlDesigner = new TestControlDesigner();
     using Button button = new Button();
     controlDesigner.Initialize(button);
 }