Exemple #1
0
        public void AddAsync_TestOfAdding()
        {
            InstrumentModel instr = new InstrumentModel();

            instr.Id    = "1";
            instr.Model = "Yamaha psr i455";
            instr.Price = 20000;
            instr.Type  = "keyboard";

            //var instrumentDbSetMock = Builder<InstrumentModel>.CreateListOfSize(1).Build().ToAsyncDbSetMock();
            _dataRepositoryMock.Setup(x => x.AddAsync((instr)));
            Assert.NotNull(_adminController.Add(instr));
        }
Exemple #2
0
        public void Add_Success()
        {
            ActionResult result = _controller.Add();

            Assert.IsNotNull(result);
        }