internal static ResultMessage ResultMessageForException(Type exceptionType, string unformattedMessage, Exception exception)
        {
            ResultMessage resultMessage = new ResultMessage(exception);
            resultMessage.Success = false;
            resultMessage.Message = string.Format(CultureInfo.InvariantCulture, unformattedMessage, exceptionType);

            return resultMessage;
        }
        private ResultMessage ConstructorWithMessageAndInnerExceptionTest(Type exceptionType)
        {
            ResultMessage resultMessage = new ResultMessage(exceptionType);
#pragma warning disable 219
            Exception createdException = null;
#pragma warning restore 219
            try
            {
                const string Message = "ExceptionMessage";
                Exception innerException = new Exception("Inner exception");
                // ReSharper disable once RedundantAssignment
                createdException = Activator.CreateInstance(exceptionType, Message, innerException) as Exception;
            }
            catch (Exception exception)
            {
                resultMessage = ResultMessageBuilder.ResultMessageForException(exceptionType, Properties.Resources.FailedToCreateExceptionParameterMessageAndInnerException, exception);
            }

            return resultMessage;
        }
        private ResultMessage DefaultConstructorTest(Type exceptionType)
        {
            ResultMessage resultMessage = new ResultMessage(exceptionType);

#pragma warning disable 219
            Exception createdException = null;
#pragma warning restore 219
            try
            {
                // ReSharper disable once RedundantAssignment
                createdException = Activator.CreateInstance(exceptionType) as Exception;
            }
            catch (Exception exception)
            {
                resultMessage = ResultMessageBuilder.ResultMessageForException(exceptionType, Properties.Resources.FailedToCreateExceptionParameterless, exception);
            }

            return resultMessage;
        }