Beispiel #1
0
        public void GetHasErrorDataIsFalse()
        {
            var exception = new JsonRpcServiceException(0L, "m");

            Assert.AreEqual(0L, exception.Code);
            Assert.AreEqual("m", exception.Message);
            Assert.IsFalse(exception.HasErrorData);
        }
Beispiel #2
0
        public void GetHasErrorDataIsTrueAndDataIsNotNull()
        {
            var exception = new JsonRpcServiceException(0L, "m", 1L);

            Assert.AreEqual(0L, exception.Code);
            Assert.AreEqual("m", exception.Message);
            Assert.IsTrue(exception.HasErrorData);
            Assert.AreEqual(1L, exception.ErrorData);
        }