public async Task GetSessionByTokenAsync_UserExists_ShouldReturnTheSession() { // Arrange context.Add(expectedSession); context.SaveChanges(); //Act var actualSession = await repository.GetSessionByToken(expectedSession.Token); //Assert Assert.AreEqual(expectedSession, actualSession); }
public async Task <Session> GetSessionByTokenAsync(string token) { var session = await repository.GetSessionByToken(token); return(session); }