ShowPopupForm() public method

Shows the popup form that is displayed when the button is clicked. This popup form is used to edit the BusinessObjects that fill the combobox.
public ShowPopupForm ( ) : void
return void
        public void Test_ShowGridAndBOEditorControlWinWithSuperClassDef()
        {
            //--------------- Set up test pack ------------------
            ClassDef.ClassDefs.Clear();
            PersonTestBO.LoadDefaultClassDefWithTestOrganisationBOLookup();
            ContactPersonTestBO.LoadDefaultClassDefWithPersonTestBOSuperClass();
            BusinessObjectCollection<OrganisationTestBO> organisationTestBOS = CreateSavedOrganisationTestBOSCollection();
            
            
            IControlFactory controlFactory = GetControlFactory();
            IExtendedComboBox extendedComboBox = CreateExtendedComboBox();
            const string propName = "OrganisationID";
            ExtendedComboBoxMapper mapper = new ExtendedComboBoxMapper(
                extendedComboBox, propName, true, controlFactory);
            mapper.BusinessObject = new ContactPersonTestBO();
           // mapper.RelatedBusinessObject = OrganisationTestBO.CreateSavedOrganisation();
            //--------------- Test Preconditions ----------------
            Assert.IsNull(mapper.PopupForm);
            //--------------- Execute Test ----------------------
            //extendedComboBox.Button.PerformClick();
            mapper.ShowPopupForm();
            //--------------- Test Result -----------------------
            Assert.IsNotNull(mapper.PopupForm);
            IFormHabanero form = mapper.PopupForm;
            Assert.AreEqual(800, form.Width);
            Assert.AreEqual(600, form.Height);
            Assert.AreEqual(1, form.Controls.Count);
            Assert.AreEqual(DockStyle.Fill, form.Controls[0].Dock);

            Assert.IsInstanceOf(typeof(IBOGridAndEditorControl), form.Controls[0]);
            IBOGridAndEditorControl andBOGridAndEditorControlWin = (IBOGridAndEditorControl)form.Controls[0];
            //Assert.AreSame(mapper.BusinessObject, BOGridAndEditorControlWin.BOEditorControlWin.BusinessObject);
            Assert.IsTrue(andBOGridAndEditorControlWin.GridControl.IsInitialised);
            IBusinessObjectCollection collection = andBOGridAndEditorControlWin.GridControl.Grid.BusinessObjectCollection;
            Assert.IsNotNull(collection);
            Assert.AreEqual(organisationTestBOS.Count, collection.Count);
            Assert.AreEqual(organisationTestBOS.Count, mapper.LookupList.Count);
        }
        public void Test_ShowGridAndBOEditorControlWinOnClick()
        {
            //--------------- Set up test pack ------------------
            BusinessObjectCollection<OrganisationTestBO> organisationTestBOs = CreateSavedOrganisationTestBOsCollection();
            IControlFactory controlFactory = GetControlFactory();
            ExtendedComboBoxWin extendedComboBox = new ExtendedComboBoxWin(controlFactory);
            const string propName = "OrganisationID";
            ExtendedComboBoxMapper mapper = new ExtendedComboBoxMapper(
                extendedComboBox, propName, true, controlFactory);
            mapper.BusinessObject = new ContactPersonTestBO();
            //--------------- Test Preconditions ----------------
            Assert.IsNull(mapper.PopupForm);
            //--------------- Execute Test ----------------------
            mapper.ShowPopupForm();
            //--------------- Test Result -----------------------
            Assert.IsNotNull(mapper.PopupForm);
            IFormHabanero form = mapper.PopupForm;
            Assert.AreEqual(800, form.Width);
            Assert.AreEqual(600, form.Height);
            Assert.AreEqual(1, form.Controls.Count);
            Assert.AreEqual(DockStyle.Fill, form.Controls[0].Dock);

            Assert.IsInstanceOf(typeof(IBOGridAndEditorControl), form.Controls[0]);
            Assert.IsInstanceOf(typeof(BOGridAndEditorControlWin), form.Controls[0]);
            BOGridAndEditorControlWin andBOGridAndEditorControlWin = (BOGridAndEditorControlWin)form.Controls[0];
            //Assert.AreSame(mapper.BusinessObject, BOGridAndEditorControlWin.BOEditorControlWin.BusinessObject);
            Assert.IsTrue(andBOGridAndEditorControlWin.GridControl.IsInitialised);
            IBusinessObjectCollection collection = andBOGridAndEditorControlWin.GridControl.Grid.BusinessObjectCollection;
            Assert.IsNotNull(collection);
            Assert.AreEqual(organisationTestBOs.Count, collection.Count);
            Assert.AreEqual(organisationTestBOs.Count, mapper.LookupList.Count);
        }