public void ShouldConvertCustomIActionMessageToActionMessage()
            {
                var action = new TestMessageAction();

                var messageAction = MessageAction.Convert(action);

                Assert.AreNotEqual(action, messageAction);

                Assert.AreEqual("MessageLabel", messageAction.Label);
                Assert.AreEqual("MessageText", messageAction.Text);
            }
            public void ShouldThrowExceptionWhenLabelIsNull()
            {
                var action = new MessageAction()
                {
                    Text = "Foo"
                };

                ExceptionAssert.Throws <InvalidOperationException>("The label cannot be null.", () =>
                {
                    MessageAction.Convert(action);
                });
            }
            public void ShouldThrowExceptionWhenTextIsNull()
            {
                var action = new MessageAction()
                {
                    Label = "Test"
                };

                ExceptionAssert.Throws <InvalidOperationException>("The text cannot be null.", () =>
                {
                    MessageAction.Convert(action);
                });
            }
            public void ShouldPreserveInstanceWhenValueIsMessageAction()
            {
                var action = new MessageAction()
                {
                    Label = "Foo",
                    Text  = "Test"
                };

                var messageAction = MessageAction.Convert(action);

                Assert.AreSame(action, messageAction);
            }