示例#1
0
        public void AddCatapultEngine_DuplicateItem()
        {
            var catapultEngineService = new CatapultEngineService(_catapultEngineRepository.Object);
            var exception             = Record.ExceptionAsync(() => catapultEngineService.CreateCatapultEngine("test"));

            Assert.IsType <DuplicateCatapultEngineException>(exception?.Result);
        }
示例#2
0
        public async void AddCatapultEngine_ValidItem()
        {
            var catapultEngineService = new CatapultEngineService(_catapultEngineRepository.Object);
            var newCatapultEngine     = await catapultEngineService.CreateCatapultEngine("enginetest");

            Assert.NotNull(newCatapultEngine);
            Assert.True(_data.Count > 1);
        }