public async Task Add_get(DepositDetails details) { await repository.AddAsync(details); DepositDetails retrieved = await repository.GetAsync(details.Id); retrieved.Should().BeEquivalentTo(details); }
public async Task Get_null() { IDb db = new MemDb(); DepositDetailsRocksRepository repository = new DepositDetailsRocksRepository(db, new DepositDetailsDecoder()); DepositDetails retrieved = await repository.GetAsync(Keccak.Zero); retrieved.Should().BeNull(); }
public async Task Update_get(DepositDetails details) { IDb db = new MemDb(); DepositDetailsRocksRepository repository = new DepositDetailsRocksRepository(db, new DepositDetailsDecoder()); await repository.UpdateAsync(details); DepositDetails retrieved = await repository.GetAsync(details.Id); retrieved.Should().BeEquivalentTo(details); }