Beispiel #1
0
        public void TestNoteGenerationAndExtraction()
        {
            var withdrawalId = 101l;
            var service      = new FireblocksWithdrawalNoteService();

            var note     = service.GenerateManualNote(withdrawalId);
            var actualId = service.GetWithdrawalIdFromNote(note);

            Assert.AreEqual(withdrawalId, actualId);
        }
 public BitgoWithdrawalService(ILogger <BitgoWithdrawalService> logger,
                               DbContextOptionsBuilder <DatabaseContext> dbContextOptionsBuilder,
                               CryptoWithdrawalService cryptoWithdrawalService,
                               IServiceBusPublisher <Withdrawal> withdrawalPublisher,
                               IWithdrawalVerificationService verificationService,
                               FireblocksWithdrawalNoteService fireblocksWithdrawalNoteService)
 {
     _logger = logger;
     _dbContextOptionsBuilder         = dbContextOptionsBuilder;
     _cryptoWithdrawalService         = cryptoWithdrawalService;
     _withdrawalPublisher             = withdrawalPublisher;
     _verificationService             = verificationService;
     _fireblocksWithdrawalNoteService = fireblocksWithdrawalNoteService;
 }
Beispiel #3
0
 public SignalFireblocksTransferJob(ISubscriber <FireblocksWithdrawalSignal> subscriber,
                                    ILogger <SignalFireblocksTransferJob> logger,
                                    DbContextOptionsBuilder <DatabaseContext> dbContextOptionsBuilder,
                                    CryptoWithdrawalService cryptoWithdrawalService,
                                    IServiceBusPublisher <Withdrawal> withdrawalPublisher,
                                    FireblocksWithdrawalNoteService fireblocksWithdrawalNoteService)
 {
     _logger = logger;
     _dbContextOptionsBuilder         = dbContextOptionsBuilder;
     _cryptoWithdrawalService         = cryptoWithdrawalService;
     _withdrawalPublisher             = withdrawalPublisher;
     _fireblocksWithdrawalNoteService = fireblocksWithdrawalNoteService;
     subscriber.Subscribe(HandleSignal);
 }