public void Test_Confirm_False_WithDelegate()
        {
            //---------------Set up test pack-------------------
            const string       message = "Confirmer message";
            const string       title   = "MessageBoxTitle";
            const DialogResult dialogResultToReturn = DialogResult.No;
            MessageBoxIcon     messageBoxIcon       = TestUtil.GetRandomEnum <MessageBoxIcon>();

            bool delegateWasCalled                    = false;
            bool confirmedParamInDelegate             = true;
            ConfirmationDelegate confirmationDelegate = delegate(bool confirmed)
            {
                delegateWasCalled        = true;
                confirmedParamInDelegate = confirmed;
            };

            MockRepository  mockRepository = new MockRepository();
            IControlFactory controlFactory = SetupControlFactoryMockWithExpectationWithDelegate(
                mockRepository, message, title, messageBoxIcon, dialogResultToReturn, confirmationDelegate);

            MessageBoxConfirmer messageBoxConfirmer = new MessageBoxConfirmer(controlFactory, title, messageBoxIcon);

            mockRepository.ReplayAll();
            //---------------Assert Precondition----------------
            Assert.IsFalse(delegateWasCalled);
            Assert.IsTrue(confirmedParamInDelegate);
            //---------------Execute Test ----------------------
            messageBoxConfirmer.Confirm(message, confirmationDelegate);
            //---------------Test Result -----------------------
            Assert.IsTrue(delegateWasCalled);
            Assert.IsFalse(confirmedParamInDelegate);
            mockRepository.VerifyAll();
        }
        public void Test_Confirm_False()
        {
            //---------------Set up test pack-------------------
            const string       message = "Confirmer message";
            const string       title   = "MessageBoxTitle";
            const DialogResult dialogResultToReturn = DialogResult.No;
            MessageBoxIcon     messageBoxIcon       = TestUtil.GetRandomEnum <MessageBoxIcon>();

            MockRepository  mockRepository = new MockRepository();
            IControlFactory controlFactory = SetupControlFactoryMockWithExpectation(mockRepository, message, title, messageBoxIcon, dialogResultToReturn);

            MessageBoxConfirmer messageBoxConfirmer = new MessageBoxConfirmer(controlFactory, title, messageBoxIcon);

            mockRepository.ReplayAll();
            //---------------Assert Precondition----------------
            //---------------Execute Test ----------------------
            bool confirmResult = messageBoxConfirmer.Confirm(message);

            //---------------Test Result -----------------------
            Assert.IsFalse(confirmResult);
            mockRepository.VerifyAll();
        }