public async Task Add_get(DepositDetails details)
        {
            await repository.AddAsync(details);

            DepositDetails retrieved = await repository.GetAsync(details.Id);

            retrieved.Should().BeEquivalentTo(details);
        }
예제 #2
0
        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();
        }
예제 #3
0
        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);
        }