Example #1
0
        public void Get_ShouldReturnAllRecords()
        {
            var userRead = new UserDataRead(_context);
            var users    = userRead.GetAll();

            Assert.Equal(_context.Users.Count(), users.Count());
        }
Example #2
0
        public async Task Get_ShouldReturnCorrectRecord(string id, string username, string firstname, string lastname)
        {
            var userRead = new UserDataRead(_context);
            var userGet  = await userRead.GetAsync(id);

            Assert.Equal(id, userGet.Id);
            Assert.Equal(username, userGet.UserName);
            Assert.Equal(firstname, userGet.FirstName);
            Assert.Equal(lastname, userGet.LastName);
        }