コード例 #1
0
        public void ConstructorWithMessage()
        {
            var message   = "Error...";
            var exception = new InjectException(message);

            Assert.AreEqual(message, exception.Message);
        }
コード例 #2
0
        public void ConstructorWithMessageAndException()
        {
            var message   = "Error...";
            var inner     = new Exception();
            var exception = new InjectException(message, inner);

            Assert.AreEqual(message, exception.Message);
            Assert.AreEqual(inner, exception.InnerException);
        }
コード例 #3
0
        public void ConstructorEmpty()
        {
            var exception = new InjectException();

            Assert.AreEqual("Exception of type 'Celerik.NetCore.Services.InjectException' was thrown.", exception.Message);
        }