Skip to content

Commit

Permalink
Add feature flag for build test.
Browse files Browse the repository at this point in the history
  • Loading branch information
winder committed Aug 20, 2024
1 parent 5387f09 commit d83f780
Showing 1 changed file with 30 additions and 10 deletions.
40 changes: 30 additions & 10 deletions execute/report/report_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -734,16 +734,36 @@ func Test_Builder_Build(t *testing.T) {
// look for error in Add or Build
foundError := false

builder := NewBuilder(
ctx,
lggr,
hasher,
tokenDataReader,
codec,
evm.EstimateProvider{},
tt.args.nonces,
tt.args.maxReportSize,
tt.args.maxGasLimit)
builder := &execReportBuilder{
ctx: ctx,
lggr: lggr,

tokenDataReader: tokenDataReader,
encoder: codec,
hasher: hasher,
estimateProvider: evm.EstimateProvider{},
sendersNonce: tt.args.nonces,
expectedNonce: make(map[cciptypes.ChainSelector]map[string]uint64),

maxReportSizeBytes: tt.args.maxReportSize,
maxGas: tt.args.maxGasLimit,
nonceCheckingEnabled: true, // TODO: remove feature flag.
}

/*
// TODO: switch back to this when removing the feature flag.
builder := NewBuilder(
ctx,
lggr,
hasher,
tokenDataReader,
codec,
evm.EstimateProvider{},
tt.args.nonces,
tt.args.maxReportSize,
tt.args.maxGasLimit)
*/

var updatedMessages []exectypes.CommitData
for _, report := range tt.args.reports {
updatedMessage, err := builder.Add(report)
Expand Down

0 comments on commit d83f780

Please sign in to comment.