コード例 #1
0
 public void SetUp()
 {
     _receiptsDb = new MemColumnsDb <ReceiptsColumns>();
     _storage    = new PersistentReceiptStorage(_receiptsDb, MainnetSpecProvider.Instance, new ReceiptsRecovery())
     {
         MigratedBlockNumber = 0
     };
     _receiptsDb.GetColumnDb(ReceiptsColumns.Blocks).Set(Keccak.Zero, Array.Empty <byte>());
 }
コード例 #2
0
        public void SetUp()
        {
            RopstenSpecProvider specProvider     = RopstenSpecProvider.Instance;
            EthereumEcdsa       ethereumEcdsa    = new(specProvider.ChainId, LimboLogs.Instance);
            ReceiptsRecovery    receiptsRecovery = new(ethereumEcdsa, specProvider);

            _receiptsDb = new MemColumnsDb <ReceiptsColumns>();
            _storage    = new PersistentReceiptStorage(_receiptsDb, MainnetSpecProvider.Instance, receiptsRecovery)
            {
                MigratedBlockNumber = 0
            };
            _receiptsDb.GetColumnDb(ReceiptsColumns.Blocks).Set(Keccak.Zero, Array.Empty <byte>());
        }
コード例 #3
0
 public void ReceiptsIterator_doesnt_throw_on_null()
 {
     _receiptsDb.GetColumnDb(ReceiptsColumns.Blocks).Set(Keccak.Zero, null !);
     _storage.TryGetReceiptsIterator(1, Keccak.Zero, out var iterator);
     iterator.TryGetNext(out _).Should().BeFalse();
 }