Please review integration test CustomerRepositoryTest (https://genericunitofworkandrepositories.codeplex.com/SourceControl/latest#main/Sample/Northwind.Test/IntegrationTests/CustomerRepositoryTests.cs) which examples this.
[TestMethod]
public void GetCustomersAsync()
{
using (IDataContextAsync context = new NorthwindContext())
using (IUnitOfWorkAsync unitOfWork = new UnitOfWork(context))
{
IRepositoryAsync<Customer> customerRepository = new Repository<Customer>(context, unitOfWork);
ICustomerService customerService = new CustomerService(customerRepository);
var asyncTask = customerService
.Query(x => x.Country == "USA")
.Include(x => x
.Orders
.Select(y => y.OrderDetails))
.OrderBy(x => x
.OrderBy(y => y.CompanyName)
.ThenBy(z => z.ContactName))
.SelectAsync();
var customers = asyncTask.Result;
Assert.IsTrue(customers.Count() > 1);
Assert.IsFalse(customers.Count(x => x.Country == "USA") == 0);
}
}