Exemplo n.º 1
0
        public void ShouldReturnErrorCodeInCaseOfException()
        {
            IErraticService  erraticServiceTest  = new ErraticServiceImpl();
            ExceptionService stubService         = new ExceptionService();
            RandomError      randomError         = erraticServiceTest.Execute(stubService);
            RandomException  lastExceptionThrown = stubService.GetLastExceptionThrown();

            Assert.Equals(lastExceptionThrown.GetError().GetCode(), randomError.GetCode());
        }