Inheritance: Habanero.Faces.Base.LookupComboBoxMapper
Esempio n. 1
0
        public void TestCustomiseLookupList_Remove()
        {
            //---------------Set up test pack-------------------
            IComboBox    cmbox    = GetControlFactory().CreateComboBox();
            const string propName = "SampleLookup2ID";
            CustomRemoveLookupComboBoxMapperStub mapperStub = new CustomRemoveLookupComboBoxMapperStub(cmbox, propName, false, GetControlFactory());
            Sample sample = new Sample();

            //---------------Execute Test ----------------------
            mapperStub.BusinessObject = sample;

            //---------------Test Result -----------------------
            Assert.AreEqual(3, cmbox.Items.Count);

            //---------------Tear Down -------------------------
            // This test changes the static class def, so force a reload
            ClassDef.ClassDefs.Remove(typeof(Sample));
        }
        public void TestCustomiseLookupList_Remove()
        {
            //---------------Set up test pack-------------------
            IComboBox cmbox = GetControlFactory().CreateComboBox();
            const string propName = "SampleLookup2ID";
            CustomRemoveLookupComboBoxMapperStub mapperStub = new CustomRemoveLookupComboBoxMapperStub(cmbox, propName, false, GetControlFactory());
            Sample sample = new Sample();

            //---------------Execute Test ----------------------
            mapperStub.BusinessObject = sample;

            //---------------Test Result -----------------------
            Assert.AreEqual(3, cmbox.Items.Count);

            //---------------Tear Down -------------------------
            // This test changes the static class def, so force a reload
            ClassDef.ClassDefs.Remove(typeof(Sample));
        }