コード例 #1
0
ファイル: PostTest.cs プロジェクト: bleach206/ToDoAPI
        public void SetUp()
        {
            _toDoController = new ToDoController(_moqService, _mockLogger, _mockCache);

            _mockCreateDTO = new Mock <CreateDTO>().Object;

            _mockCreateDTO.Name        = "Protect Daenerys Stormborn";
            _mockCreateDTO.Description = "Protecter of Dragons";
        }
コード例 #2
0
        public void SetUp()
        {
            _mockService   = new Mock <ITaskService>();
            _mockCreateDTO = new Mock <CreateDTO>().Object;

            _mockCreateDTO.Name = "Protect Daenerys Stormborn";

            _mockCreateTasksDTO      = new Mock <CreateTasksDTO>().Object;
            _mockCreateTasksDTO.Name = "Protect Daenerys Stormborn";
        }
コード例 #3
0
        public void SetUp()
        {
            _toDoController = new ToDoController(_moqService, _mockLogger);
            var task = new Mock <CreateTaskDTO>().Object;

            task.Name = "Guard and kill everyone else";
            var list = new List <CreateTaskDTO>();

            list.Add(task);

            _mockCreateDTO = new Mock <CreateDTO>().Object;

            _mockCreateDTO.Name        = "Protect Daenerys Stormborn";
            _mockCreateDTO.Description = "Protecter of Dragons";

            _mockCreateDTO.Tasks = list;
        }