상속: Habanero.Faces.Base.CheckBoxMapper
 public void Test_AddClickEventHandler_WhenMapperUsingControlAdapter_ShouldAddBehaviours()
 {
     //---------------Set up test pack-------------------
     var checkBoxWin = GetWinFormsControlAdapter();
     DisposeOnTearDown(checkBoxWin);
     var checkBoxMapper = new CheckBoxMapperStub(checkBoxWin);
     //---------------Assert Precondition----------------
     Assert.IsInstanceOf<CheckBox>(checkBoxMapper.GetControl());
     //---------------Execute Test ----------------------
     var checkBoxStrategyWin = new CheckBoxStrategyWin();
     checkBoxStrategyWin.AddClickEventHandler(checkBoxMapper);
     //---------------Assert Result----------------------
     Assert.IsTrue(true, "If an error was not thrown then we are OK");
 }
 public void Test_AddClickEventHandler_WhenMapperUsingHabaneroControl_ShouldAddBehaviours()
 {
     //---------------Set up test pack-------------------
     var checkBoxWin = new CheckBoxWin {Name = "TestCheckBox", Checked = false, Enabled = true};
     DisposeOnTearDown(checkBoxWin);
     var checkBoxMapper = new CheckBoxMapperStub(checkBoxWin);
     //---------------Assert Precondition----------------
     Assert.IsInstanceOf<ICheckBox>(checkBoxMapper.Control);
     //---------------Execute Test ----------------------
     var checkBoxStrategyWin = new CheckBoxStrategyWin();
     checkBoxStrategyWin.AddClickEventHandler(checkBoxMapper);
     //---------------Assert Result----------------------
     Assert.IsTrue(true, "If an error was not thrown then we are OK");
 }
예제 #3
0
        public void Test_AddClickEventHandler_WhenMapperUsingControlAdapter_ShouldAddBehaviours()
        {
            //---------------Set up test pack-------------------
            var checkBoxWin = GetWinFormsControlAdapter();

            DisposeOnTearDown(checkBoxWin);
            var checkBoxMapper = new CheckBoxMapperStub(checkBoxWin);

            //---------------Assert Precondition----------------
            Assert.IsInstanceOf <CheckBox>(checkBoxMapper.GetControl());
            //---------------Execute Test ----------------------
            var checkBoxStrategyWin = new CheckBoxStrategyWin();

            checkBoxStrategyWin.AddClickEventHandler(checkBoxMapper);
            //---------------Assert Result----------------------
            Assert.IsTrue(true, "If an error was not thrown then we are OK");
        }
예제 #4
0
        public void Test_AddClickEventHandler_WhenMapperUsingHabaneroControl_ShouldAddBehaviours()
        {
            //---------------Set up test pack-------------------
            var checkBoxWin = new CheckBoxWin {
                Name = "TestCheckBox", Checked = false, Enabled = true
            };

            DisposeOnTearDown(checkBoxWin);
            var checkBoxMapper = new CheckBoxMapperStub(checkBoxWin);

            //---------------Assert Precondition----------------
            Assert.IsInstanceOf <ICheckBox>(checkBoxMapper.Control);
            //---------------Execute Test ----------------------
            var checkBoxStrategyWin = new CheckBoxStrategyWin();

            checkBoxStrategyWin.AddClickEventHandler(checkBoxMapper);
            //---------------Assert Result----------------------
            Assert.IsTrue(true, "If an error was not thrown then we are OK");
        }