Skip to content

Commit

Permalink
Fix integration test, and add debug output
Browse files Browse the repository at this point in the history
  • Loading branch information
reductionista committed Dec 20, 2023
1 parent e08fc14 commit 79fa968
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion core/internal/features/ocr2/features_ocr2_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -429,6 +429,13 @@ juelsPerFeeCoinSource = """
metaLock.Unlock()
assert.Len(t, em, 0, "expected metadata %v", em)

t.Logf("======= Summary =======")
for i := 0; i < 20; i++ {
roundData, err := ocrContract.GetRoundData(nil, big.NewInt(int64(i)))
require.NoError(t, err)
t.Logf("RoundId: %d, AnsweredInRound: %d, Answer: %d, StartedAt: %v, UpdatedAt: %v", roundData.RoundId, roundData.AnsweredInRound, roundData.Answer, roundData.StartedAt, roundData.UpdatedAt)
}

// Assert we can read the latest config digest and epoch after a report has been submitted.
contractABI, err := abi.JSON(strings.NewReader(ocr2aggregator.OCR2AggregatorABI))
require.NoError(t, err)
Expand All @@ -445,7 +452,7 @@ juelsPerFeeCoinSource = """
assert.Equal(t, digestAndEpoch.Epoch, epoch)
latestTransmissionDetails, err := ocrContract.LatestTransmissionDetails(nil)
require.NoError(t, err)
assert.Equal(t, latestTransmissionDetails.LatestAnswer, big.NewInt(20))
assert.Equal(t, big.NewInt(2*int64(retVal)), latestTransmissionDetails.LatestAnswer)
latestRoundRequested, err := ocrContract.FilterRoundRequested(&bind.FilterOpts{Start: 0, End: nil}, []common.Address{{}})
require.NoError(t, err)
if latestRoundRequested.Next() { // Shouldn't this come back non-nil?
Expand Down

0 comments on commit 79fa968

Please sign in to comment.