public async Task GetByCompanyAsync()
        {
            Log.MinimumLevel = LogLevel.Trace;

            var employee1 = await _employeeRepository.AddAsync(EmployeeGenerator.Generate(age: 19, companyId: EmployeeGenerator.DefaultCompanyId), o => o.ImmediateConsistency());

            var employee2 = await _employeeRepository.AddAsync(EmployeeGenerator.Generate(age: 20), o => o.ImmediateConsistency());

            var results = await _employeeRepository.GetAllByCompanyAsync(employee1.CompanyId);

            Assert.Equal(1, results.Total);
            Assert.Equal(employee1, results.Documents.First());

            results = await _employeeRepository.GetAllByCompanyAsync(employee2.CompanyId);

            Assert.Equal(1, results.Total);
            Assert.Equal(employee2, results.Documents.First());

            results = await _employeeRepository.GetAllByCompaniesWithFieldEqualsAsync(new string[] { employee1.CompanyId });

            Assert.Equal(1, results.Total);

            results = await _employeeRepository.GetAllByCompaniesWithFieldEqualsAsync(new string[] { employee1.CompanyId, employee2.CompanyId });

            Assert.Equal(2, results.Total);

            Assert.Equal(1, await _employeeRepository.GetCountByCompanyAsync(employee1.CompanyId));
            await _employeeRepository.RemoveAsync(employee1, o => o.Cache().ImmediateConsistency());

            var result = await _employeeRepository.FindAsync(q => q.FieldCondition(e => e.Age, ComparisonOperator.Equals, 12));

            Assert.Empty(result.Documents);

            var query = new RepositoryQuery <Employee>();

            query.FieldEquals(e => e.Age, 12);
            result = await _employeeRepository.FindAsync(q => query);

            Assert.Empty(result.Documents);

            Assert.Equal(1, await _employeeRepository.CountAsync());
            Assert.Equal(0, await _employeeRepository.GetCountByCompanyAsync(employee1.CompanyId));

            query = new RepositoryQuery <Employee>();
            query.FieldEquals(e => e.Name, null);
            result = await _employeeRepository.FindAsync(q => query);

            Assert.Single(result.Documents);

            query = new RepositoryQuery <Employee>();
            query.FieldNotEquals(e => e.Name, null);
            result = await _employeeRepository.FindAsync(q => query);

            Assert.Empty(result.Documents);
        }