diff --git a/test/bdd/features/publish-errors.feature b/test/bdd/features/publish-errors.feature index 7ac8d8f531..4b7cc2e44d 100644 --- a/test/bdd/features/publish-errors.feature +++ b/test/bdd/features/publish-errors.feature @@ -11,7 +11,7 @@ Feature: Publish errors test # When I call publish on node 1 with validAssertion # And Last publish finished with status: PublishStartError -## + @publish-errors Scenario: Node is not able to validate assertion on the network Given I setup 4 nodes diff --git a/test/bdd/steps/api/publish.js b/test/bdd/steps/api/publish.js index 4e7093589c..f84a404ac3 100644 --- a/test/bdd/steps/api/publish.js +++ b/test/bdd/steps/api/publish.js @@ -45,6 +45,7 @@ When( /^I call publish on ot-node (\d+) directly with ([^"]*)/, { timeout: 60000 }, async function publish(node, requestName) { + this.logger.log(`I call publish on ot-node ${node} directly`); expect( !!requests[requestName], `Request body with name: ${requestName} not found!`, @@ -92,12 +93,12 @@ Given('I wait for last publish to finalize', { timeout: 80000 }, async function assert.fail('Unable to get publish result'); } // eslint-disable-next-line no-await-in-loop - await setTimeout(4000); + await setTimeout(5000); } }); Given( - /Last publish finished with status: ([COMPLETED|FAILED|PublishValidateAssertionError,PUblishStartError]+)$/, + /Last publish finished with status: ([COMPLETED|FAILED|PublishValidateAssertionError,PublishStartError]+)$/, { timeout: 60000 }, async function lastPublishFinished(status) { this.logger.log(`Last publish finished with status: ${status}`); diff --git a/test/bdd/steps/common.js b/test/bdd/steps/common.js index 470aaa64fc..f7dc79fa16 100644 --- a/test/bdd/steps/common.js +++ b/test/bdd/steps/common.js @@ -22,6 +22,7 @@ function getBlockchainConfiguration(localBlockchain, privateKey, publicKey, mana evmOperationalWalletPublicKey: publicKey, evmOperationalWalletPrivateKey: privateKey, evmManagementWalletPublicKey: managementKey, + evmManagementPublicKey: managementKey, }, }, }, @@ -99,8 +100,8 @@ Given(/^I setup (\d+) node[s]*$/, { timeout: 80000 }, function nodeSetup(nodeCou let nodesStarted = 0; for (let i = 0; i < nodeCount; i += 1) { const nodeIndex = currentNumberOfNodes + i; - const wallet = wallets[nodeIndex]; - const managementWallet = wallets[nodeIndex + 28]; + const wallet = wallets[nodeIndex + 1]; + const managementWallet = wallets[nodeIndex + 1 + 27]; const rpcPort = 8901 + nodeIndex; const nodeName = `origintrail-test-${nodeIndex}`; @@ -205,8 +206,8 @@ Given( let nodesStarted = 0; for (let i = 0; i < nodeCount; i += 1) { const nodeIndex = currentNumberOfNodes + i; - const wallet = wallets[nodeIndex]; - const managementWallet = wallets[nodeIndex + 28]; + const wallet = wallets[nodeIndex + 1]; + const managementWallet = wallets[nodeIndex + 1 + 27]; const rpcPort = 8901 + nodeIndex; const nodeName = `origintrail-test-${nodeIndex}`; const nodeConfiguration = DeepExtend( @@ -267,8 +268,8 @@ Given( { timeout: 120000 }, function setupPublishNode(nodeIndex, done) { this.logger.log(`I setup node ${nodeIndex} with invalid configuration`); - const wallet = this.state.localBlockchain.getWallets()[nodeIndex - 1]; - const managementWallet = this.state.localBlockchain.getWallets()[nodeIndex - 1 + 28]; + const wallet = this.state.localBlockchain.getWallets()[nodeIndex]; + const managementWallet = this.state.localBlockchain.getWallets()[nodeIndex + 27]; const rpcPort = 8901 + nodeIndex - 1; const nodeName = `origintrail-test-${nodeIndex - 1}`; const nodeConfiguration = DeepExtend( @@ -278,7 +279,7 @@ Given( this, wallet, managementWallet, - nodeIndex, + nodeIndex - 1, nodeName, rpcPort, ), diff --git a/test/bdd/steps/config/origintrail-test-bootstrap-config.json b/test/bdd/steps/config/origintrail-test-bootstrap-config.json index 2789035757..268346d1b0 100644 --- a/test/bdd/steps/config/origintrail-test-bootstrap-config.json +++ b/test/bdd/steps/config/origintrail-test-bootstrap-config.json @@ -13,8 +13,8 @@ "hubContractAddress": "0x378ec78F621E2C8Aeff345b39334c38B0Bb7b96F", "evmOperationalWalletPublicKey": "0x1152b7ea23b7b9890ce2e9abf95119038d7644e0", "evmOperationalWalletPrivateKey": "3cf97be6177acdd12796b387f58f84f177d0fe20d8558004e8db9a41cf90392a", - "evmManagementWalletPublicKey": "0x20bd8f91585bebf91ae96c897c38429ebc2291c7", - "evmManagementPublicKey": "0x20bd8f91585bebf91ae96c897c38429ebc2291c7" + "evmManagementWalletPublicKey": "0x76014481ed80a4bb57eba8f279d0d2489db5d136", + "evmManagementPublicKey": "0x76014481ed80a4bb57eba8f279d0d2489db5d136" } } } diff --git a/test/bdd/steps/config/origintrail-test-node-config.json b/test/bdd/steps/config/origintrail-test-node-config.json index 7a1f1aa964..35211d1c06 100644 --- a/test/bdd/steps/config/origintrail-test-node-config.json +++ b/test/bdd/steps/config/origintrail-test-node-config.json @@ -13,8 +13,8 @@ "hubContractAddress": "0x378ec78F621E2C8Aeff345b39334c38B0Bb7b96F", "evmOperationalWalletPublicKey": "0x19ad96f87f8e1c13e99a98d8174e00f5a7c82df1", "evmOperationalWalletPrivateKey": "1e60c8e9aa35064cd2eaa4c005bda2b76ef1a858feebb6c8e131c472d16f9740", - "evmManagementWalletPublicKey": "0x1de33ab36099f60c6a41a1b8f71939428773b169", - "evmManagementPublicKey" : "0x1de33ab36099f60c6a41a1b8f71939428773b169" + "evmManagementWalletPublicKey": "0xc96dfe1017168f5b5e2518df8048b7b6da9f7bd1", + "evmManagementPublicKey" : "0xc96dfe1017168f5b5e2518df8048b7b6da9f7bd1" } } }