public async Task GetByIdAsync_CreateAndGet_LockReturned()
        {
            // Arrage
            var @lock   = _fixure.Create <Locks.Entities.Lock>();
            var created = await _repository.TryCreateAsync(@lock, _userId);

            // Act
            var result = await _repository.GetByIdAsync(created.Id, _userId);

            // Assert
            result.Should().BeEquivalentTo(created, opt => opt.WithStrictOrdering());
        }
Exemple #2
0
 public Task <Lock> GetByIdAsync(Guid id, string userId)
 {
     return(_locksRepository.GetByIdAsync(id, userId));
 }