public async Task Post_Term_Success() { var term = new Term { Id = "001", Name = "A", StartDate = DateTime.Now, EndDate = DateTime.Now.AddMonths(3), UniversityId = "001" }; var result = await _controller.PostTerm(term); Assert.IsType <CreatedAtActionResult>(result.Result); Assert.Single(_context.Terms.ToList()); Assert.Equal(term, _context.Terms.ToList()[0]); }