diff --git a/services/horizon/internal/ingest/processor_runner_test.go b/services/horizon/internal/ingest/processor_runner_test.go index 6e307d3260..a4fd59a72b 100644 --- a/services/horizon/internal/ingest/processor_runner_test.go +++ b/services/horizon/internal/ingest/processor_runner_test.go @@ -30,7 +30,7 @@ func TestProcessorRunnerRunHistoryArchiveIngestionHistoryArchive(t *testing.T) { q := &mockDBQ{} defer mock.AssertExpectationsForObjects(t, q) historyAdapter := &mockHistoryArchiveAdapter{} - defer mock.AssertExpectationsForObjects(t, historyAdapter) // this will fail + defer mock.AssertExpectationsForObjects(t, historyAdapter) m := &ingest.MockChangeReader{} m.On("Close").Return(nil).Once() @@ -65,7 +65,14 @@ func TestProcessorRunnerRunHistoryArchiveIngestionHistoryArchive(t *testing.T) { ).Once() batchBuilders := mockChangeProcessorBatchBuilders(q, ctx, true) - defer mock.AssertExpectationsForObjects(t, batchBuilders...) // currently failing + defer mock.AssertExpectationsForObjects(t, batchBuilders...) + + assert.IsType(t, &history.MockAccountSignersBatchInsertBuilder{}, batchBuilders[0]) + batchBuilders[0].(*history.MockAccountSignersBatchInsertBuilder).On("Add", history.AccountSigner{ + Account: "GAAZI4TCR3TY5OJHCTJC2A4QSY6CJWJH5IAJTGKIN2ER7LBNVKOCCWN7", + Signer: "GAAZI4TCR3TY5OJHCTJC2A4QSY6CJWJH5IAJTGKIN2ER7LBNVKOCCWN7", + Weight: 1, + }).Return(nil).Once() assert.IsType(t, &history.MockAccountsBatchInsertBuilder{}, batchBuilders[1]) batchBuilders[1].(*history.MockAccountsBatchInsertBuilder).On("Add", history.AccountEntry{ @@ -76,13 +83,6 @@ func TestProcessorRunnerRunHistoryArchiveIngestionHistoryArchive(t *testing.T) { MasterWeight: 1, }).Return(nil).Once() - assert.IsType(t, &history.MockAccountSignersBatchInsertBuilder{}, batchBuilders[0]) - batchBuilders[0].(*history.MockAccountSignersBatchInsertBuilder).On("Add", history.AccountSigner{ - Account: "GAAZI4TCR3TY5OJHCTJC2A4QSY6CJWJH5IAJTGKIN2ER7LBNVKOCCWN7", - Signer: "GAAZI4TCR3TY5OJHCTJC2A4QSY6CJWJH5IAJTGKIN2ER7LBNVKOCCWN7", - Weight: 1, - }).Return(nil).Once() - q.MockQAssetStats.On("InsertAssetStats", ctx, []history.ExpAssetStat{}, 100000). Return(nil)