diff --git a/integration-tests/deployment/ccip/deploy_home_chain.go b/integration-tests/deployment/ccip/deploy_home_chain.go index 1d7c9f98fdc..3639567f382 100644 --- a/integration-tests/deployment/ccip/deploy_home_chain.go +++ b/integration-tests/deployment/ccip/deploy_home_chain.go @@ -800,6 +800,11 @@ func AddDON( return err } + mapOfframpOCR3Configs := make(map[cctypes.PluginType]offramp.MultiOCR3BaseOCRConfigArgs) + for _, config := range offrampOCR3Configs { + mapOfframpOCR3Configs[cctypes.PluginType(config.OcrPluginType)] = config + } + for _, pluginType := range []cctypes.PluginType{cctypes.PluginTypeCCIPCommit, cctypes.PluginTypeCCIPExec} { ocrConfig, err := offRamp.LatestConfigDetails(&bind.CallOpts{ Context: context.Background(), @@ -809,24 +814,24 @@ func AddDON( } // TODO: assertions to be done as part of full state // resprentation validation CCIP-3047 - if offrampOCR3Configs[pluginType].ConfigDigest != ocrConfig.ConfigInfo.ConfigDigest { + if mapOfframpOCR3Configs[pluginType].ConfigDigest != ocrConfig.ConfigInfo.ConfigDigest { return fmt.Errorf("%s OCR3 config digest mismatch", pluginType.String()) } - if offrampOCR3Configs[pluginType].F != ocrConfig.ConfigInfo.F { + if mapOfframpOCR3Configs[pluginType].F != ocrConfig.ConfigInfo.F { return fmt.Errorf("%s OCR3 config F mismatch", pluginType.String()) } - if offrampOCR3Configs[pluginType].IsSignatureVerificationEnabled != ocrConfig.ConfigInfo.IsSignatureVerificationEnabled { + if mapOfframpOCR3Configs[pluginType].IsSignatureVerificationEnabled != ocrConfig.ConfigInfo.IsSignatureVerificationEnabled { return fmt.Errorf("%s OCR3 config signature verification mismatch", pluginType.String()) } if pluginType == cctypes.PluginTypeCCIPCommit { // only commit will set signers, exec doesn't need them. - for i, signer := range offrampOCR3Configs[pluginType].Signers { + for i, signer := range mapOfframpOCR3Configs[pluginType].Signers { if !bytes.Equal(signer.Bytes(), ocrConfig.Signers[i].Bytes()) { return fmt.Errorf("%s OCR3 config signer mismatch", pluginType.String()) } } } - for i, transmitter := range offrampOCR3Configs[pluginType].Transmitters { + for i, transmitter := range mapOfframpOCR3Configs[pluginType].Transmitters { if !bytes.Equal(transmitter.Bytes(), ocrConfig.Transmitters[i].Bytes()) { return fmt.Errorf("%s OCR3 config transmitter mismatch", pluginType.String()) } diff --git a/integration-tests/deployment/devenv/chain.go b/integration-tests/deployment/devenv/chain.go index de02437fec7..10a888c1d0a 100644 --- a/integration-tests/deployment/devenv/chain.go +++ b/integration-tests/deployment/devenv/chain.go @@ -75,11 +75,7 @@ func NewChains(logger logger.Logger, configs []ChainConfig) (map[uint64]deployme blockNumber = receipt.BlockNumber.Uint64() } if receipt.Status == 0 { - t, _, err := ec.TransactionByHash(context.Background(), tx.Hash()) - if err != nil { - return fmt.Errorf("tx %s reverted, failed to get transaction: %w", tx.Hash().Hex(), err) - } - errReason, err := deployment.GetErrorReasonFromTx(ec, chainCfg.DeployerKey.From, *t, receipt) + errReason, err := deployment.GetErrorReasonFromTx(ec, chainCfg.DeployerKey.From, *tx, receipt) if err == nil && errReason != "" { return fmt.Errorf("tx %s reverted,error reason: %s", tx.Hash().Hex(), errReason) } diff --git a/integration-tests/deployment/memory/environment.go b/integration-tests/deployment/memory/environment.go index b462086405b..641a88d72bb 100644 --- a/integration-tests/deployment/memory/environment.go +++ b/integration-tests/deployment/memory/environment.go @@ -62,7 +62,11 @@ func generateMemoryChain(t *testing.T, inputs map[uint64]EVMChain) map[uint64]de continue } if receipt.Status == 0 { - t.Logf("Status (reverted) %d for txhash %s\n", receipt.Status, tx.Hash().Hex()) + errReason, err := deployment.GetErrorReasonFromTx(chain.Backend, chain.DeployerKey.From, *tx, receipt) + if err == nil && errReason != "" { + return 0, fmt.Errorf("tx %s reverted,error reason: %s", tx.Hash().Hex(), errReason) + } + return 0, fmt.Errorf("tx %s reverted, could not decode error reason", tx.Hash().Hex()) } return receipt.BlockNumber.Uint64(), nil }