From 90fca1c55e656e04fd4a815434e9647f956fa733 Mon Sep 17 00:00:00 2001 From: Antony Denyer Date: Wed, 13 Oct 2021 05:28:05 +0100 Subject: [PATCH] Use web3j gradle plugin for acceptance tests (#2872) Automatically generate wrappers for all contracts in acceptance-tests/tests/contracts Signed-off-by: Antony Denyer Co-authored-by: Sally MacFarlane --- acceptance-tests/tests/build.gradle | 15 + .../CrossContractReader.sol | 0 .../web3j => contracts}/EventEmitter.sol | 0 .../RemoteSimpleStorage.sol | 0 .../web3j => contracts}/RevertReason.sol | 0 .../web3j => contracts}/SimpleStorage.sol | 0 .../ClusterAcceptanceTest.java | 2 +- .../ClusterNoDiscoveryAcceptanceTest.java | 2 +- ...ClusterThreadNodeRunnerAcceptanceTest.java | 2 +- .../P2pDisabledAcceptanceTest.java | 2 +- .../StaticNodesAcceptanceTest.java | 2 +- .../DeploySmartContractAcceptanceTest.java | 2 +- .../DeployTransactionAcceptanceTest.java | 2 +- .../jsonrpc}/EventEmitterAcceptanceTest.java | 2 +- .../jsonrpc}/RevertReasonAcceptanceTest.java | 2 +- .../BftPrivacyClusterAcceptanceTest.java | 2 +- .../privacy/EnclaveErrorAcceptanceTest.java | 2 +- .../privacy/EthSignerAcceptanceTest.java | 2 +- .../privacy/OnchainPrivacyAcceptanceTest.java | 2 +- .../OnchainPrivacyAcceptanceTestBase.java | 2 +- .../PluginPrivacySigningAcceptanceTest.java | 2 +- ...etStateRootOnchainGroupAcceptanceTest.java | 1 - .../privacy/PrivacyClusterAcceptanceTest.java | 4 +- .../privacy/PrivacyGroupAcceptanceTest.java | 2 +- .../privacy/contracts/PrivacyGroupTest.java | 2 +- .../privacy/contracts/PrivacyProxyTest.java | 2 +- .../OnchainMultiTenancyAcceptanceTest.java | 4 +- .../web3j/generated/CrossContractReader.abi | 1 - .../web3j/generated/CrossContractReader.bin | 1 - .../web3j/generated/CrossContractReader.java | 284 ------------------ .../tests/web3j/generated/EventEmitter.abi | 1 - .../tests/web3j/generated/EventEmitter.bin | 1 - .../tests/web3j/generated/EventEmitter.java | 251 ---------------- .../web3j/generated/RemoteSimpleStorage.java | 196 ------------ .../tests/web3j/generated/RevertReason.abi | 1 - .../tests/web3j/generated/RevertReason.bin | 1 - .../tests/web3j/generated/RevertReason.java | 175 ----------- .../tests/web3j/generated/SimpleStorage.abi | 1 - .../tests/web3j/generated/SimpleStorage.bin | 1 - .../tests/web3j/generated/SimpleStorage.java | 178 ----------- 40 files changed, 37 insertions(+), 1115 deletions(-) rename acceptance-tests/tests/{src/test/java/org/hyperledger/besu/tests/web3j => contracts}/CrossContractReader.sol (100%) rename acceptance-tests/tests/{src/test/java/org/hyperledger/besu/tests/web3j => contracts}/EventEmitter.sol (100%) rename acceptance-tests/tests/{src/test/java/org/hyperledger/besu/tests/web3j => contracts}/RemoteSimpleStorage.sol (100%) rename acceptance-tests/tests/{src/test/java/org/hyperledger/besu/tests/web3j => contracts}/RevertReason.sol (100%) rename acceptance-tests/tests/{src/test/java/org/hyperledger/besu/tests/web3j => contracts}/SimpleStorage.sol (100%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/{ => bootstrap}/ClusterAcceptanceTest.java (96%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/{ => bootstrap}/ClusterNoDiscoveryAcceptanceTest.java (97%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/{ => bootstrap}/ClusterThreadNodeRunnerAcceptanceTest.java (97%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/{ => bootstrap}/P2pDisabledAcceptanceTest.java (97%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/{ => bootstrap}/StaticNodesAcceptanceTest.java (96%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/{web3j => acceptance/jsonrpc}/DeploySmartContractAcceptanceTest.java (96%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/{web3j => acceptance/jsonrpc}/DeployTransactionAcceptanceTest.java (96%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/{web3j => acceptance/jsonrpc}/EventEmitterAcceptanceTest.java (97%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/{web3j => acceptance/jsonrpc}/RevertReasonAcceptanceTest.java (97%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/{web3j => acceptance}/privacy/BftPrivacyClusterAcceptanceTest.java (99%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/{web3j => acceptance}/privacy/EnclaveErrorAcceptanceTest.java (99%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/{web3j => acceptance}/privacy/EthSignerAcceptanceTest.java (99%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/{web3j => acceptance}/privacy/OnchainPrivacyAcceptanceTest.java (99%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/{web3j => acceptance}/privacy/OnchainPrivacyAcceptanceTestBase.java (99%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/{web3j => acceptance}/privacy/PrivacyClusterAcceptanceTest.java (95%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/{web3j => acceptance}/privacy/PrivacyGroupAcceptanceTest.java (99%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/{web3j => acceptance}/privacy/contracts/PrivacyGroupTest.java (99%) rename acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/{web3j => acceptance}/privacy/contracts/PrivacyProxyTest.java (99%) delete mode 100644 acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/CrossContractReader.abi delete mode 100644 acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/CrossContractReader.bin delete mode 100644 acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/CrossContractReader.java delete mode 100644 acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/EventEmitter.abi delete mode 100644 acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/EventEmitter.bin delete mode 100644 acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/EventEmitter.java delete mode 100755 acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RemoteSimpleStorage.java delete mode 100644 acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RevertReason.abi delete mode 100644 acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RevertReason.bin delete mode 100644 acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RevertReason.java delete mode 100644 acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/SimpleStorage.abi delete mode 100644 acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/SimpleStorage.bin delete mode 100644 acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/SimpleStorage.java diff --git a/acceptance-tests/tests/build.gradle b/acceptance-tests/tests/build.gradle index fd968801db..80a72cb02b 100644 --- a/acceptance-tests/tests/build.gradle +++ b/acceptance-tests/tests/build.gradle @@ -11,6 +11,21 @@ * specific language governing permissions and limitations under the License. */ +plugins { + id 'org.web3j' version '4.8.4' + id 'org.web3j.solidity' version '0.3.2' +} + +web3j { + generatedPackageName = 'org.hyperledger.besu.tests.web3j.generated' +} + +sourceSets.main.solidity.srcDirs = ["$projectDir/contracts"] + +solidity { + resolvePackages = false +} + dependencies { implementation project(':crypto') diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/CrossContractReader.sol b/acceptance-tests/tests/contracts/CrossContractReader.sol similarity index 100% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/CrossContractReader.sol rename to acceptance-tests/tests/contracts/CrossContractReader.sol diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/EventEmitter.sol b/acceptance-tests/tests/contracts/EventEmitter.sol similarity index 100% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/EventEmitter.sol rename to acceptance-tests/tests/contracts/EventEmitter.sol diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/RemoteSimpleStorage.sol b/acceptance-tests/tests/contracts/RemoteSimpleStorage.sol similarity index 100% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/RemoteSimpleStorage.sol rename to acceptance-tests/tests/contracts/RemoteSimpleStorage.sol diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/RevertReason.sol b/acceptance-tests/tests/contracts/RevertReason.sol similarity index 100% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/RevertReason.sol rename to acceptance-tests/tests/contracts/RevertReason.sol diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/SimpleStorage.sol b/acceptance-tests/tests/contracts/SimpleStorage.sol similarity index 100% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/SimpleStorage.sol rename to acceptance-tests/tests/contracts/SimpleStorage.sol diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/ClusterAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/ClusterAcceptanceTest.java similarity index 96% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/ClusterAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/ClusterAcceptanceTest.java index 3a29e7082e..c4c9e42671 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/ClusterAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/ClusterAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.acceptance; +package org.hyperledger.besu.tests.acceptance.bootstrap; import org.hyperledger.besu.tests.acceptance.dsl.AcceptanceTestBase; import org.hyperledger.besu.tests.acceptance.dsl.node.Node; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/ClusterNoDiscoveryAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/ClusterNoDiscoveryAcceptanceTest.java similarity index 97% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/ClusterNoDiscoveryAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/ClusterNoDiscoveryAcceptanceTest.java index 9328cdaae0..6c7c812799 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/ClusterNoDiscoveryAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/ClusterNoDiscoveryAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.acceptance; +package org.hyperledger.besu.tests.acceptance.bootstrap; import org.hyperledger.besu.tests.acceptance.dsl.AcceptanceTestBase; import org.hyperledger.besu.tests.acceptance.dsl.node.Node; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/ClusterThreadNodeRunnerAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/ClusterThreadNodeRunnerAcceptanceTest.java similarity index 97% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/ClusterThreadNodeRunnerAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/ClusterThreadNodeRunnerAcceptanceTest.java index d4da3988ca..805749a0bf 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/ClusterThreadNodeRunnerAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/ClusterThreadNodeRunnerAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.acceptance; +package org.hyperledger.besu.tests.acceptance.bootstrap; import org.hyperledger.besu.tests.acceptance.dsl.AcceptanceTestBase; import org.hyperledger.besu.tests.acceptance.dsl.node.BesuNode; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/P2pDisabledAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/P2pDisabledAcceptanceTest.java similarity index 97% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/P2pDisabledAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/P2pDisabledAcceptanceTest.java index d863e1ad16..aa71839b18 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/P2pDisabledAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/P2pDisabledAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.acceptance; +package org.hyperledger.besu.tests.acceptance.bootstrap; import org.hyperledger.besu.tests.acceptance.dsl.AcceptanceTestBase; import org.hyperledger.besu.tests.acceptance.dsl.node.Node; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/StaticNodesAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/StaticNodesAcceptanceTest.java similarity index 96% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/StaticNodesAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/StaticNodesAcceptanceTest.java index 69719d6df4..1f28a4a9f3 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/StaticNodesAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/bootstrap/StaticNodesAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.acceptance; +package org.hyperledger.besu.tests.acceptance.bootstrap; import org.hyperledger.besu.tests.acceptance.dsl.AcceptanceTestBase; import org.hyperledger.besu.tests.acceptance.dsl.WaitUtils; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/DeploySmartContractAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/jsonrpc/DeploySmartContractAcceptanceTest.java similarity index 96% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/DeploySmartContractAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/jsonrpc/DeploySmartContractAcceptanceTest.java index 712881f7f3..6a06674df4 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/DeploySmartContractAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/jsonrpc/DeploySmartContractAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.web3j; +package org.hyperledger.besu.tests.acceptance.jsonrpc; import org.hyperledger.besu.tests.acceptance.dsl.AcceptanceTestBase; import org.hyperledger.besu.tests.acceptance.dsl.node.BesuNode; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/DeployTransactionAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/jsonrpc/DeployTransactionAcceptanceTest.java similarity index 96% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/DeployTransactionAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/jsonrpc/DeployTransactionAcceptanceTest.java index b8eca851fd..451418fa5f 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/DeployTransactionAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/jsonrpc/DeployTransactionAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.web3j; +package org.hyperledger.besu.tests.acceptance.jsonrpc; import org.hyperledger.besu.datatypes.Hash; import org.hyperledger.besu.tests.acceptance.dsl.AcceptanceTestBase; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/EventEmitterAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/jsonrpc/EventEmitterAcceptanceTest.java similarity index 97% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/EventEmitterAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/jsonrpc/EventEmitterAcceptanceTest.java index 91e1673c3e..9644cc2b62 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/EventEmitterAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/jsonrpc/EventEmitterAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.web3j; +package org.hyperledger.besu.tests.acceptance.jsonrpc; import static org.assertj.core.api.Assertions.assertThat; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/RevertReasonAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/jsonrpc/RevertReasonAcceptanceTest.java similarity index 97% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/RevertReasonAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/jsonrpc/RevertReasonAcceptanceTest.java index 8e59382e71..bccbe6d9e0 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/RevertReasonAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/jsonrpc/RevertReasonAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.web3j; +package org.hyperledger.besu.tests.acceptance.jsonrpc; import static org.hyperledger.besu.tests.web3j.generated.RevertReason.FUNC_REVERTWITHOUTREVERTREASON; import static org.hyperledger.besu.tests.web3j.generated.RevertReason.FUNC_REVERTWITHREVERTREASON; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/BftPrivacyClusterAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/BftPrivacyClusterAcceptanceTest.java similarity index 99% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/BftPrivacyClusterAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/BftPrivacyClusterAcceptanceTest.java index 94f53db6a5..382207c168 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/BftPrivacyClusterAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/BftPrivacyClusterAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.web3j.privacy; +package org.hyperledger.besu.tests.acceptance.privacy; import org.hyperledger.besu.tests.acceptance.dsl.privacy.PrivacyAcceptanceTestBase; import org.hyperledger.besu.tests.acceptance.dsl.privacy.PrivacyNode; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/EnclaveErrorAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/EnclaveErrorAcceptanceTest.java similarity index 99% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/EnclaveErrorAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/EnclaveErrorAcceptanceTest.java index b981ac0e5d..5b60511af7 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/EnclaveErrorAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/EnclaveErrorAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.web3j.privacy; +package org.hyperledger.besu.tests.acceptance.privacy; import static org.assertj.core.api.Assertions.catchThrowable; import static org.assertj.core.api.AssertionsForClassTypes.assertThat; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/EthSignerAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/EthSignerAcceptanceTest.java similarity index 99% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/EthSignerAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/EthSignerAcceptanceTest.java index ef21cae605..3ebf9a2c89 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/EthSignerAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/EthSignerAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.web3j.privacy; +package org.hyperledger.besu.tests.acceptance.privacy; import static org.web3j.utils.Restriction.UNRESTRICTED; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/OnchainPrivacyAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/OnchainPrivacyAcceptanceTest.java similarity index 99% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/OnchainPrivacyAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/OnchainPrivacyAcceptanceTest.java index 490d28a5f4..d3443719a0 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/OnchainPrivacyAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/OnchainPrivacyAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.web3j.privacy; +package org.hyperledger.besu.tests.acceptance.privacy; import static org.assertj.core.api.Assertions.assertThat; import static org.assertj.core.api.Assertions.assertThatThrownBy; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/OnchainPrivacyAcceptanceTestBase.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/OnchainPrivacyAcceptanceTestBase.java similarity index 99% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/OnchainPrivacyAcceptanceTestBase.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/OnchainPrivacyAcceptanceTestBase.java index b5ffa7681d..11dc345a2f 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/OnchainPrivacyAcceptanceTestBase.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/OnchainPrivacyAcceptanceTestBase.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.web3j.privacy; +package org.hyperledger.besu.tests.acceptance.privacy; import static org.assertj.core.api.Assertions.assertThat; import static org.hyperledger.besu.ethereum.core.PrivacyParameters.ONCHAIN_PRIVACY_PROXY; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/PluginPrivacySigningAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/PluginPrivacySigningAcceptanceTest.java index 9f19bb3ace..c6f812cc57 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/PluginPrivacySigningAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/PluginPrivacySigningAcceptanceTest.java @@ -87,7 +87,7 @@ public class PluginPrivacySigningAcceptanceTest extends PrivacyAcceptanceTestBas minerNode .execute( ethTransactions.getTransactionReceipt( - "0x3d232ce6be958f99ff6a669cbc759bca19e35f5561045998cf843ec9a8b28530")) + "0xa65bc3b91e85a864a90be966f7b6da88cb7a1dcefe972c8840dfa5f6d25a4299")) .get(); assertThat(pmtReceipt.getStatus()).isEqualTo("0x1"); diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/PrivDebugGetStateRootOnchainGroupAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/PrivDebugGetStateRootOnchainGroupAcceptanceTest.java index 3731cd3343..6a32d68ff3 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/PrivDebugGetStateRootOnchainGroupAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/PrivDebugGetStateRootOnchainGroupAcceptanceTest.java @@ -21,7 +21,6 @@ import org.hyperledger.besu.tests.acceptance.dsl.privacy.PrivacyNode; import org.hyperledger.besu.tests.acceptance.dsl.privacy.account.PrivacyAccountResolver; import org.hyperledger.besu.tests.acceptance.dsl.transaction.privacy.PrivacyRequestFactory; import org.hyperledger.besu.tests.web3j.generated.EventEmitter; -import org.hyperledger.besu.tests.web3j.privacy.OnchainPrivacyAcceptanceTestBase; import org.hyperledger.enclave.testutil.EnclaveType; import java.io.IOException; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/PrivacyClusterAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/PrivacyClusterAcceptanceTest.java similarity index 95% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/PrivacyClusterAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/PrivacyClusterAcceptanceTest.java index f884f1f63c..24d2c01ba2 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/PrivacyClusterAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/PrivacyClusterAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.web3j.privacy; +package org.hyperledger.besu.tests.acceptance.privacy; import static org.assertj.core.api.Assertions.assertThat; import static org.hyperledger.besu.ethereum.core.PrivacyParameters.DEFAULT_PRIVACY; @@ -56,7 +56,7 @@ import org.web3j.utils.Numeric; public class PrivacyClusterAcceptanceTest extends PrivacyAcceptanceTestBase { private static final String eventEmitterDeployed = - "0x6080604052600436106100565763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416633fa4f245811461005b5780636057361d1461008257806367e404ce146100ae575b600080fd5b34801561006757600080fd5b506100706100ec565b60408051918252519081900360200190f35b34801561008e57600080fd5b506100ac600480360360208110156100a557600080fd5b50356100f2565b005b3480156100ba57600080fd5b506100c3610151565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b60025490565b604080513381526020810183905281517fc9db20adedc6cf2b5d25252b101ab03e124902a73fcb12b753f3d1aaa2d8f9f5929181900390910190a16002556001805473ffffffffffffffffffffffffffffffffffffffff191633179055565b60015473ffffffffffffffffffffffffffffffffffffffff169056fea165627a7a72305820c7f729cb24e05c221f5aa913700793994656f233fe2ce3b9fd9a505ea17e8d8a0029"; + "0x608060405234801561001057600080fd5b506004361061005d577c010000000000000000000000000000000000000000000000000000000060003504633fa4f24581146100625780636057361d1461007c57806367e404ce1461009b575b600080fd5b61006a6100cc565b60408051918252519081900360200190f35b6100996004803603602081101561009257600080fd5b50356100d2565b005b6100a3610131565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b60025490565b604080513381526020810183905281517fc9db20adedc6cf2b5d25252b101ab03e124902a73fcb12b753f3d1aaa2d8f9f5929181900390910190a16002556001805473ffffffffffffffffffffffffffffffffffffffff191633179055565b60015473ffffffffffffffffffffffffffffffffffffffff169056fea265627a7a7231582090b93fa1c20946b6f8b2ad11f1b2c0aa357217287877d3d1cfeef69bd7f4788564736f6c63430005110032"; private final PrivacyNode alice; private final PrivacyNode bob; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/PrivacyGroupAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/PrivacyGroupAcceptanceTest.java similarity index 99% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/PrivacyGroupAcceptanceTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/PrivacyGroupAcceptanceTest.java index 2ebbb26eb8..e33ab53df3 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/PrivacyGroupAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/PrivacyGroupAcceptanceTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.web3j.privacy; +package org.hyperledger.besu.tests.acceptance.privacy; import static org.assertj.core.api.Assertions.assertThat; import static org.web3j.utils.Restriction.RESTRICTED; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/contracts/PrivacyGroupTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/contracts/PrivacyGroupTest.java similarity index 99% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/contracts/PrivacyGroupTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/contracts/PrivacyGroupTest.java index 998568fc23..f487c15ab8 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/contracts/PrivacyGroupTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/contracts/PrivacyGroupTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.web3j.privacy.contracts; +package org.hyperledger.besu.tests.acceptance.privacy.contracts; import static org.assertj.core.api.Assertions.assertThat; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/contracts/PrivacyProxyTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/contracts/PrivacyProxyTest.java similarity index 99% rename from acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/contracts/PrivacyProxyTest.java rename to acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/contracts/PrivacyProxyTest.java index f4217fcccd..46dfe21d21 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/privacy/contracts/PrivacyProxyTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/contracts/PrivacyProxyTest.java @@ -12,7 +12,7 @@ * * SPDX-License-Identifier: Apache-2.0 */ -package org.hyperledger.besu.tests.web3j.privacy.contracts; +package org.hyperledger.besu.tests.acceptance.privacy.contracts; import static org.assertj.core.api.Assertions.assertThat; import static org.assertj.core.api.Assertions.assertThatThrownBy; diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/multitenancy/OnchainMultiTenancyAcceptanceTest.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/multitenancy/OnchainMultiTenancyAcceptanceTest.java index 42b88e1777..ff0cc7072e 100644 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/multitenancy/OnchainMultiTenancyAcceptanceTest.java +++ b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/acceptance/privacy/multitenancy/OnchainMultiTenancyAcceptanceTest.java @@ -26,8 +26,8 @@ import org.hyperledger.besu.tests.acceptance.dsl.privacy.transaction.CreateOncha import org.hyperledger.besu.tests.acceptance.dsl.privacy.util.LogFilterJsonParameter; import org.hyperledger.besu.tests.acceptance.dsl.transaction.perm.PermissioningTransactions; import org.hyperledger.besu.tests.acceptance.dsl.transaction.privacy.PrivacyRequestFactory; +import org.hyperledger.besu.tests.acceptance.privacy.OnchainPrivacyAcceptanceTestBase; import org.hyperledger.besu.tests.web3j.generated.EventEmitter; -import org.hyperledger.besu.tests.web3j.privacy.OnchainPrivacyAcceptanceTestBase; import org.hyperledger.enclave.testutil.EnclaveType; import java.math.BigInteger; @@ -66,7 +66,7 @@ public class OnchainMultiTenancyAcceptanceTest extends OnchainPrivacyAcceptanceT } private static final String eventEmitterDeployed = - "0x6080604052600436106100565763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416633fa4f245811461005b5780636057361d1461008257806367e404ce146100ae575b600080fd5b34801561006757600080fd5b506100706100ec565b60408051918252519081900360200190f35b34801561008e57600080fd5b506100ac600480360360208110156100a557600080fd5b50356100f2565b005b3480156100ba57600080fd5b506100c3610151565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b60025490565b604080513381526020810183905281517fc9db20adedc6cf2b5d25252b101ab03e124902a73fcb12b753f3d1aaa2d8f9f5929181900390910190a16002556001805473ffffffffffffffffffffffffffffffffffffffff191633179055565b60015473ffffffffffffffffffffffffffffffffffffffff169056fea165627a7a72305820c7f729cb24e05c221f5aa913700793994656f233fe2ce3b9fd9a505ea17e8d8a0029"; + "0x608060405234801561001057600080fd5b506004361061005d577c010000000000000000000000000000000000000000000000000000000060003504633fa4f24581146100625780636057361d1461007c57806367e404ce1461009b575b600080fd5b61006a6100cc565b60408051918252519081900360200190f35b6100996004803603602081101561009257600080fd5b50356100d2565b005b6100a3610131565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b60025490565b604080513381526020810183905281517fc9db20adedc6cf2b5d25252b101ab03e124902a73fcb12b753f3d1aaa2d8f9f5929181900390910190a16002556001805473ffffffffffffffffffffffffffffffffffffffff191633179055565b60015473ffffffffffffffffffffffffffffffffffffffff169056fea265627a7a7231582090b93fa1c20946b6f8b2ad11f1b2c0aa357217287877d3d1cfeef69bd7f4788564736f6c63430005110032"; private static final PermissioningTransactions permissioningTransactions = new PermissioningTransactions(); diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/CrossContractReader.abi b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/CrossContractReader.abi deleted file mode 100644 index 36edfd6c59..0000000000 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/CrossContractReader.abi +++ /dev/null @@ -1 +0,0 @@ -[{"constant":false,"inputs":[{"name":"crossAddress","type":"address"}],"name":"remoteDestroy","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"crossAddress","type":"address"}],"name":"deployRemote","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"deploy","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"destroy","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"emitter_address","type":"address"}],"name":"read","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"increment","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"crossAddress","type":"address"}],"name":"incrementRemote","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"anonymous":false,"inputs":[{"indexed":false,"name":"contractAddress","type":"address"}],"name":"NewEventEmitter","type":"event"}] \ No newline at end of file diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/CrossContractReader.bin b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/CrossContractReader.bin deleted file mode 100644 index a18bc7505c..0000000000 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/CrossContractReader.bin +++ /dev/null @@ -1 +0,0 @@ -608060405234801561001057600080fd5b506104b7806100206000396000f3fe608060405234801561001057600080fd5b506004361061007d5760003560e01c806383197ef01161005b57806383197ef0146100d8578063a087a87e146100e0578063d09de08a14610118578063e689ef8a146101205761007d565b8063305155f9146100825780635374ded2146100aa578063775c300c146100d0575b600080fd5b6100a86004803603602081101561009857600080fd5b50356001600160a01b0316610146565b005b6100a8600480360360208110156100c057600080fd5b50356001600160a01b03166101a2565b6100a86101e2565b6100a8610250565b610106600480360360208110156100f657600080fd5b50356001600160a01b0316610253565b60408051918252519081900360200190f35b6100a86102c5565b6100a86004803603602081101561013657600080fd5b50356001600160a01b03166102d0565b6000819050806001600160a01b03166383197ef06040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561018657600080fd5b505af115801561019a573d6000803e3d6000fd5b505050505050565b6000819050806001600160a01b031663775c300c6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561018657600080fd5b60006040516101f090610310565b604051809103906000f08015801561020c573d6000803e3d6000fd5b50604080516001600160a01b038316815290519192507f9ac6876e0aa40667ffeaa9b359b5ed924f4cdd0e029eb6e9c369e78c68f711fb919081900360200190a150565b33ff5b600080829050806001600160a01b0316633fa4f2456040518163ffffffff1660e01b815260040160206040518083038186803b15801561029257600080fd5b505afa1580156102a6573d6000803e3d6000fd5b505050506040513d60208110156102bc57600080fd5b50519392505050565b600080546001019055565b6000819050806001600160a01b031663d09de08a6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561018657600080fd5b6101658061031e8339019056fe608060405234801561001057600080fd5b50600080546001600160a01b03191633179055610133806100326000396000f3fe6080604052348015600f57600080fd5b5060043610603c5760003560e01c80633fa4f2451460415780636057361d14605957806367e404ce146075575b600080fd5b60476097565b60408051918252519081900360200190f35b607360048036036020811015606d57600080fd5b5035609d565b005b607b60ef565b604080516001600160a01b039092168252519081900360200190f35b60025490565b604080513381526020810183905281517fc9db20adedc6cf2b5d25252b101ab03e124902a73fcb12b753f3d1aaa2d8f9f5929181900390910190a1600255600180546001600160a01b03191633179055565b6001546001600160a01b03169056fea265627a7a72305820dc1ce4d08260105d146ec5efa5274950ee9e66f81ff18994d44a40fbd33e45c064736f6c634300050a0032a265627a7a72305820d71e5a225a48fdeb043aaba4264138353b3443a28658bacec7570e108659ad2864736f6c634300050a0032 \ No newline at end of file diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/CrossContractReader.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/CrossContractReader.java deleted file mode 100644 index eb20299c20..0000000000 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/CrossContractReader.java +++ /dev/null @@ -1,284 +0,0 @@ -/* - * Copyright ConsenSys AG. - * - * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on - * an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the - * specific language governing permissions and limitations under the License. - * - * SPDX-License-Identifier: Apache-2.0 - */ -package org.hyperledger.besu.tests.web3j.generated; - -import java.math.BigInteger; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collections; -import java.util.List; - -import io.reactivex.Flowable; -import org.web3j.abi.EventEncoder; -import org.web3j.abi.TypeReference; -import org.web3j.abi.datatypes.Address; -import org.web3j.abi.datatypes.Event; -import org.web3j.abi.datatypes.Function; -import org.web3j.abi.datatypes.Type; -import org.web3j.abi.datatypes.generated.Uint256; -import org.web3j.crypto.Credentials; -import org.web3j.protocol.Web3j; -import org.web3j.protocol.core.DefaultBlockParameter; -import org.web3j.protocol.core.RemoteCall; -import org.web3j.protocol.core.RemoteFunctionCall; -import org.web3j.protocol.core.methods.request.EthFilter; -import org.web3j.protocol.core.methods.response.BaseEventResponse; -import org.web3j.protocol.core.methods.response.Log; -import org.web3j.protocol.core.methods.response.TransactionReceipt; -import org.web3j.tx.Contract; -import org.web3j.tx.TransactionManager; -import org.web3j.tx.gas.ContractGasProvider; - -/** - * Auto generated code. - * - *

Do not modify! - * - *

Please use the web3j command line tools, - * or the org.web3j.codegen.SolidityFunctionWrapperGenerator in the codegen module to update. - * - *

Generated with web3j version 4.5.0. - */ -@SuppressWarnings("rawtypes") -public class CrossContractReader extends Contract { - private static final String BINARY = - "608060405234801561001057600080fd5b506104b7806100206000396000f3fe608060405234801561001057600080fd5b506004361061007d5760003560e01c806383197ef01161005b57806383197ef0146100d8578063a087a87e146100e0578063d09de08a14610118578063e689ef8a146101205761007d565b8063305155f9146100825780635374ded2146100aa578063775c300c146100d0575b600080fd5b6100a86004803603602081101561009857600080fd5b50356001600160a01b0316610146565b005b6100a8600480360360208110156100c057600080fd5b50356001600160a01b03166101a2565b6100a86101e2565b6100a8610250565b610106600480360360208110156100f657600080fd5b50356001600160a01b0316610253565b60408051918252519081900360200190f35b6100a86102c5565b6100a86004803603602081101561013657600080fd5b50356001600160a01b03166102d0565b6000819050806001600160a01b03166383197ef06040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561018657600080fd5b505af115801561019a573d6000803e3d6000fd5b505050505050565b6000819050806001600160a01b031663775c300c6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561018657600080fd5b60006040516101f090610310565b604051809103906000f08015801561020c573d6000803e3d6000fd5b50604080516001600160a01b038316815290519192507f9ac6876e0aa40667ffeaa9b359b5ed924f4cdd0e029eb6e9c369e78c68f711fb919081900360200190a150565b33ff5b600080829050806001600160a01b0316633fa4f2456040518163ffffffff1660e01b815260040160206040518083038186803b15801561029257600080fd5b505afa1580156102a6573d6000803e3d6000fd5b505050506040513d60208110156102bc57600080fd5b50519392505050565b600080546001019055565b6000819050806001600160a01b031663d09de08a6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561018657600080fd5b6101658061031e8339019056fe608060405234801561001057600080fd5b50600080546001600160a01b03191633179055610133806100326000396000f3fe6080604052348015600f57600080fd5b5060043610603c5760003560e01c80633fa4f2451460415780636057361d14605957806367e404ce146075575b600080fd5b60476097565b60408051918252519081900360200190f35b607360048036036020811015606d57600080fd5b5035609d565b005b607b60ef565b604080516001600160a01b039092168252519081900360200190f35b60025490565b604080513381526020810183905281517fc9db20adedc6cf2b5d25252b101ab03e124902a73fcb12b753f3d1aaa2d8f9f5929181900390910190a1600255600180546001600160a01b03191633179055565b6001546001600160a01b03169056fea265627a7a72305820dc1ce4d08260105d146ec5efa5274950ee9e66f81ff18994d44a40fbd33e45c064736f6c634300050a0032a265627a7a72305820d71e5a225a48fdeb043aaba4264138353b3443a28658bacec7570e108659ad2864736f6c634300050a0032"; - - public static final String FUNC_REMOTEDESTROY = "remoteDestroy"; - - public static final String FUNC_DEPLOYREMOTE = "deployRemote"; - - public static final String FUNC_DESTROY = "destroy"; - - public static final String FUNC_READ = "read"; - - public static final String FUNC_INCREMENT = "increment"; - - public static final String FUNC_INCREMENTREMOTE = "incrementRemote"; - - public static final Event NEWEVENTEMITTER_EVENT = - new Event( - "NewEventEmitter", Arrays.>asList(new TypeReference

() {})); - - @Deprecated - protected CrossContractReader( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final BigInteger gasPrice, - final BigInteger gasLimit) { - super(BINARY, contractAddress, web3j, credentials, gasPrice, gasLimit); - } - - protected CrossContractReader( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final ContractGasProvider contractGasProvider) { - super(BINARY, contractAddress, web3j, credentials, contractGasProvider); - } - - @Deprecated - protected CrossContractReader( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final BigInteger gasPrice, - final BigInteger gasLimit) { - super(BINARY, contractAddress, web3j, transactionManager, gasPrice, gasLimit); - } - - protected CrossContractReader( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final ContractGasProvider contractGasProvider) { - super(BINARY, contractAddress, web3j, transactionManager, contractGasProvider); - } - - public RemoteFunctionCall remoteDestroy(final String crossAddress) { - final Function function = - new Function( - FUNC_REMOTEDESTROY, - Arrays.asList(new org.web3j.abi.datatypes.Address(160, crossAddress)), - Collections.>emptyList()); - return executeRemoteCallTransaction(function); - } - - public RemoteFunctionCall deployRemote(final String crossAddress) { - final Function function = - new Function( - FUNC_DEPLOYREMOTE, - Arrays.asList(new org.web3j.abi.datatypes.Address(160, crossAddress)), - Collections.>emptyList()); - return executeRemoteCallTransaction(function); - } - - public RemoteFunctionCall deploy() { - final Function function = - new Function(FUNC_DEPLOY, Arrays.asList(), Collections.>emptyList()); - return executeRemoteCallTransaction(function); - } - - public RemoteFunctionCall destroy() { - final Function function = - new Function( - FUNC_DESTROY, Arrays.asList(), Collections.>emptyList()); - return executeRemoteCallTransaction(function); - } - - public RemoteFunctionCall read(final String emitter_address) { - final Function function = - new Function( - FUNC_READ, - Arrays.asList(new org.web3j.abi.datatypes.Address(160, emitter_address)), - Arrays.>asList(new TypeReference() {})); - return executeRemoteCallSingleValueReturn(function, BigInteger.class); - } - - public RemoteFunctionCall increment() { - final Function function = - new Function( - FUNC_INCREMENT, Arrays.asList(), Collections.>emptyList()); - return executeRemoteCallTransaction(function); - } - - public RemoteFunctionCall incrementRemote(final String crossAddress) { - final Function function = - new Function( - FUNC_INCREMENTREMOTE, - Arrays.asList(new org.web3j.abi.datatypes.Address(160, crossAddress)), - Collections.>emptyList()); - return executeRemoteCallTransaction(function); - } - - public List getNewEventEmitterEvents( - final TransactionReceipt transactionReceipt) { - List valueList = - extractEventParametersWithLog(NEWEVENTEMITTER_EVENT, transactionReceipt); - ArrayList responses = - new ArrayList(valueList.size()); - for (Contract.EventValuesWithLog eventValues : valueList) { - NewEventEmitterEventResponse typedResponse = new NewEventEmitterEventResponse(); - typedResponse.log = eventValues.getLog(); - typedResponse.contractAddress = (String) eventValues.getNonIndexedValues().get(0).getValue(); - responses.add(typedResponse); - } - return responses; - } - - public Flowable newEventEmitterEventFlowable( - final EthFilter filter) { - return web3j - .ethLogFlowable(filter) - .map( - new io.reactivex.functions.Function() { - @Override - public NewEventEmitterEventResponse apply(final Log log) { - Contract.EventValuesWithLog eventValues = - extractEventParametersWithLog(NEWEVENTEMITTER_EVENT, log); - NewEventEmitterEventResponse typedResponse = new NewEventEmitterEventResponse(); - typedResponse.log = log; - typedResponse.contractAddress = - (String) eventValues.getNonIndexedValues().get(0).getValue(); - return typedResponse; - } - }); - } - - public Flowable newEventEmitterEventFlowable( - final DefaultBlockParameter startBlock, final DefaultBlockParameter endBlock) { - EthFilter filter = new EthFilter(startBlock, endBlock, getContractAddress()); - filter.addSingleTopic(EventEncoder.encode(NEWEVENTEMITTER_EVENT)); - return newEventEmitterEventFlowable(filter); - } - - @Deprecated - public static CrossContractReader load( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return new CrossContractReader(contractAddress, web3j, credentials, gasPrice, gasLimit); - } - - @Deprecated - public static CrossContractReader load( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return new CrossContractReader(contractAddress, web3j, transactionManager, gasPrice, gasLimit); - } - - public static CrossContractReader load( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final ContractGasProvider contractGasProvider) { - return new CrossContractReader(contractAddress, web3j, credentials, contractGasProvider); - } - - public static CrossContractReader load( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final ContractGasProvider contractGasProvider) { - return new CrossContractReader(contractAddress, web3j, transactionManager, contractGasProvider); - } - - public static RemoteCall deploy( - final Web3j web3j, - final Credentials credentials, - final ContractGasProvider contractGasProvider) { - return deployRemoteCall( - CrossContractReader.class, web3j, credentials, contractGasProvider, BINARY, ""); - } - - @Deprecated - public static RemoteCall deploy( - final Web3j web3j, - final Credentials credentials, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return deployRemoteCall( - CrossContractReader.class, web3j, credentials, gasPrice, gasLimit, BINARY, ""); - } - - public static RemoteCall deploy( - final Web3j web3j, - final TransactionManager transactionManager, - final ContractGasProvider contractGasProvider) { - return deployRemoteCall( - CrossContractReader.class, web3j, transactionManager, contractGasProvider, BINARY, ""); - } - - @Deprecated - public static RemoteCall deploy( - final Web3j web3j, - final TransactionManager transactionManager, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return deployRemoteCall( - CrossContractReader.class, web3j, transactionManager, gasPrice, gasLimit, BINARY, ""); - } - - public static class NewEventEmitterEventResponse extends BaseEventResponse { - public String contractAddress; - } -} diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/EventEmitter.abi b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/EventEmitter.abi deleted file mode 100644 index 4f6111952a..0000000000 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/EventEmitter.abi +++ /dev/null @@ -1 +0,0 @@ -[{"constant":true,"inputs":[],"name":"value","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_amount","type":"uint256"}],"name":"store","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"sender","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"name":"_to","type":"address"},{"indexed":false,"name":"_amount","type":"uint256"}],"name":"stored","type":"event"}] \ No newline at end of file diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/EventEmitter.bin b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/EventEmitter.bin deleted file mode 100644 index 4707225e47..0000000000 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/EventEmitter.bin +++ /dev/null @@ -1 +0,0 @@ -608060405234801561001057600080fd5b5060008054600160a060020a03191633179055610199806100326000396000f3fe6080604052600436106100565763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416633fa4f245811461005b5780636057361d1461008257806367e404ce146100ae575b600080fd5b34801561006757600080fd5b506100706100ec565b60408051918252519081900360200190f35b34801561008e57600080fd5b506100ac600480360360208110156100a557600080fd5b50356100f2565b005b3480156100ba57600080fd5b506100c3610151565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b60025490565b604080513381526020810183905281517fc9db20adedc6cf2b5d25252b101ab03e124902a73fcb12b753f3d1aaa2d8f9f5929181900390910190a16002556001805473ffffffffffffffffffffffffffffffffffffffff191633179055565b60015473ffffffffffffffffffffffffffffffffffffffff169056fea165627a7a72305820c7f729cb24e05c221f5aa913700793994656f233fe2ce3b9fd9a505ea17e8d8a0029 \ No newline at end of file diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/EventEmitter.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/EventEmitter.java deleted file mode 100644 index 37b888f0b3..0000000000 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/EventEmitter.java +++ /dev/null @@ -1,251 +0,0 @@ -/* - * Copyright ConsenSys AG. - * - * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on - * an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the - * specific language governing permissions and limitations under the License. - * - * SPDX-License-Identifier: Apache-2.0 - */ -package org.hyperledger.besu.tests.web3j.generated; - -import java.math.BigInteger; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collections; -import java.util.List; - -import io.reactivex.Flowable; -import org.web3j.abi.EventEncoder; -import org.web3j.abi.TypeReference; -import org.web3j.abi.datatypes.Address; -import org.web3j.abi.datatypes.Event; -import org.web3j.abi.datatypes.Function; -import org.web3j.abi.datatypes.Type; -import org.web3j.abi.datatypes.generated.Uint256; -import org.web3j.crypto.Credentials; -import org.web3j.protocol.Web3j; -import org.web3j.protocol.core.DefaultBlockParameter; -import org.web3j.protocol.core.RemoteCall; -import org.web3j.protocol.core.RemoteFunctionCall; -import org.web3j.protocol.core.methods.request.EthFilter; -import org.web3j.protocol.core.methods.response.BaseEventResponse; -import org.web3j.protocol.core.methods.response.Log; -import org.web3j.protocol.core.methods.response.TransactionReceipt; -import org.web3j.tx.Contract; -import org.web3j.tx.TransactionManager; -import org.web3j.tx.gas.ContractGasProvider; - -/** - * Auto generated code. - * - *

Do not modify! - * - *

Please use the web3j command line tools, - * or the org.web3j.codegen.SolidityFunctionWrapperGenerator in the codegen module to update. - * - *

Generated with web3j version 4.4.1. - */ -@SuppressWarnings("rawtypes") -public class EventEmitter extends Contract { - public static final String BINARY = - "608060405234801561001057600080fd5b5060008054600160a060020a03191633179055610199806100326000396000f3fe6080604052600436106100565763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416633fa4f245811461005b5780636057361d1461008257806367e404ce146100ae575b600080fd5b34801561006757600080fd5b506100706100ec565b60408051918252519081900360200190f35b34801561008e57600080fd5b506100ac600480360360208110156100a557600080fd5b50356100f2565b005b3480156100ba57600080fd5b506100c3610151565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b60025490565b604080513381526020810183905281517fc9db20adedc6cf2b5d25252b101ab03e124902a73fcb12b753f3d1aaa2d8f9f5929181900390910190a16002556001805473ffffffffffffffffffffffffffffffffffffffff191633179055565b60015473ffffffffffffffffffffffffffffffffffffffff169056fea165627a7a72305820c7f729cb24e05c221f5aa913700793994656f233fe2ce3b9fd9a505ea17e8d8a0029"; - - public static final String FUNC_VALUE = "value"; - - public static final String FUNC_STORE = "store"; - - public static final String FUNC_SENDER = "sender"; - - public static final Event STORED_EVENT = - new Event( - "stored", - Arrays.>asList( - new TypeReference

() {}, new TypeReference() {})); - - @Deprecated - protected EventEmitter( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final BigInteger gasPrice, - final BigInteger gasLimit) { - super(BINARY, contractAddress, web3j, credentials, gasPrice, gasLimit); - } - - protected EventEmitter( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final ContractGasProvider contractGasProvider) { - super(BINARY, contractAddress, web3j, credentials, contractGasProvider); - } - - @Deprecated - protected EventEmitter( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final BigInteger gasPrice, - final BigInteger gasLimit) { - super(BINARY, contractAddress, web3j, transactionManager, gasPrice, gasLimit); - } - - protected EventEmitter( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final ContractGasProvider contractGasProvider) { - super(BINARY, contractAddress, web3j, transactionManager, contractGasProvider); - } - - public RemoteFunctionCall value() { - final Function function = - new Function( - FUNC_VALUE, - Arrays.asList(), - Arrays.>asList(new TypeReference() {})); - return executeRemoteCallSingleValueReturn(function, BigInteger.class); - } - - public RemoteFunctionCall store(final BigInteger _amount) { - final Function function = - new Function( - FUNC_STORE, - Arrays.asList(new org.web3j.abi.datatypes.generated.Uint256(_amount)), - Collections.>emptyList()); - return executeRemoteCallTransaction(function); - } - - public RemoteFunctionCall sender() { - final Function function = - new Function( - FUNC_SENDER, - Arrays.asList(), - Arrays.>asList(new TypeReference
() {})); - return executeRemoteCallSingleValueReturn(function, String.class); - } - - public List getStoredEvents(final TransactionReceipt transactionReceipt) { - List valueList = - extractEventParametersWithLog(STORED_EVENT, transactionReceipt); - ArrayList responses = new ArrayList(valueList.size()); - for (Contract.EventValuesWithLog eventValues : valueList) { - StoredEventResponse typedResponse = new StoredEventResponse(); - typedResponse.log = eventValues.getLog(); - typedResponse._to = (String) eventValues.getNonIndexedValues().get(0).getValue(); - typedResponse._amount = (BigInteger) eventValues.getNonIndexedValues().get(1).getValue(); - responses.add(typedResponse); - } - return responses; - } - - public Flowable storedEventFlowable(final EthFilter filter) { - return web3j - .ethLogFlowable(filter) - .map( - new io.reactivex.functions.Function() { - @Override - public StoredEventResponse apply(final Log log) { - Contract.EventValuesWithLog eventValues = - extractEventParametersWithLog(STORED_EVENT, log); - StoredEventResponse typedResponse = new StoredEventResponse(); - typedResponse.log = log; - typedResponse._to = (String) eventValues.getNonIndexedValues().get(0).getValue(); - typedResponse._amount = - (BigInteger) eventValues.getNonIndexedValues().get(1).getValue(); - return typedResponse; - } - }); - } - - public Flowable storedEventFlowable( - final DefaultBlockParameter startBlock, final DefaultBlockParameter endBlock) { - EthFilter filter = new EthFilter(startBlock, endBlock, getContractAddress()); - filter.addSingleTopic(EventEncoder.encode(STORED_EVENT)); - return storedEventFlowable(filter); - } - - @Deprecated - public static EventEmitter load( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return new EventEmitter(contractAddress, web3j, credentials, gasPrice, gasLimit); - } - - @Deprecated - public static EventEmitter load( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return new EventEmitter(contractAddress, web3j, transactionManager, gasPrice, gasLimit); - } - - public static EventEmitter load( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final ContractGasProvider contractGasProvider) { - return new EventEmitter(contractAddress, web3j, credentials, contractGasProvider); - } - - public static EventEmitter load( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final ContractGasProvider contractGasProvider) { - return new EventEmitter(contractAddress, web3j, transactionManager, contractGasProvider); - } - - public static RemoteCall deploy( - final Web3j web3j, - final Credentials credentials, - final ContractGasProvider contractGasProvider) { - return deployRemoteCall( - EventEmitter.class, web3j, credentials, contractGasProvider, BINARY, ""); - } - - public static RemoteCall deploy( - final Web3j web3j, - final TransactionManager transactionManager, - final ContractGasProvider contractGasProvider) { - return deployRemoteCall( - EventEmitter.class, web3j, transactionManager, contractGasProvider, BINARY, ""); - } - - @Deprecated - public static RemoteCall deploy( - final Web3j web3j, - final Credentials credentials, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return deployRemoteCall(EventEmitter.class, web3j, credentials, gasPrice, gasLimit, BINARY, ""); - } - - @Deprecated - public static RemoteCall deploy( - final Web3j web3j, - final TransactionManager transactionManager, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return deployRemoteCall( - EventEmitter.class, web3j, transactionManager, gasPrice, gasLimit, BINARY, ""); - } - - public static class StoredEventResponse extends BaseEventResponse { - public String _to; - - public BigInteger _amount; - } -} diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RemoteSimpleStorage.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RemoteSimpleStorage.java deleted file mode 100755 index 3cb66b2b73..0000000000 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RemoteSimpleStorage.java +++ /dev/null @@ -1,196 +0,0 @@ -/* - * Copyright contributors to Hyperledger Besu - * - * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on - * an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the - * specific language governing permissions and limitations under the License. - * - * SPDX-License-Identifier: Apache-2.0 - */ - -package org.hyperledger.besu.tests.web3j.generated; - -import java.math.BigInteger; -import java.util.Arrays; -import java.util.Collections; - -import org.web3j.abi.TypeReference; -import org.web3j.abi.datatypes.Address; -import org.web3j.abi.datatypes.Function; -import org.web3j.abi.datatypes.Type; -import org.web3j.abi.datatypes.generated.Uint256; -import org.web3j.crypto.Credentials; -import org.web3j.protocol.Web3j; -import org.web3j.protocol.core.RemoteCall; -import org.web3j.protocol.core.RemoteFunctionCall; -import org.web3j.protocol.core.methods.response.TransactionReceipt; -import org.web3j.tx.Contract; -import org.web3j.tx.TransactionManager; -import org.web3j.tx.gas.ContractGasProvider; - -/** - * Auto generated code. - * - *

Do not modify! - * - *

Please use the web3j command line tools, - * or the org.web3j.codegen.SolidityFunctionWrapperGenerator in the codegen module to update. - * - *

Generated with web3j version 4.5.0. - */ -@SuppressWarnings("rawtypes") -public class RemoteSimpleStorage extends Contract { - private static final String BINARY = - "608060405234801561001057600080fd5b5061034c806100206000396000f3fe608060405234801561001057600080fd5b5060043610610069576000357c01000000000000000000000000000000000000000000000000000000009004806360fe47b11461006e5780636be0d6bf1461009c5780636d4ce63c146100e6578063f1efe24c14610104575b600080fd5b61009a6004803603602081101561008457600080fd5b8101908080359060200190929190505050610148565b005b6100a46101f3565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6100ee610218565b6040518082815260200191505060405180910390f35b6101466004803603602081101561011a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506102dd565b005b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166360fe47b1826040518263ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040180828152602001915050600060405180830381600087803b1580156101d857600080fd5b505af11580156101ec573d6000803e3d6000fd5b5050505050565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636d4ce63c6040518163ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040160206040518083038186803b15801561029d57600080fd5b505afa1580156102b1573d6000803e3d6000fd5b505050506040513d60208110156102c757600080fd5b8101908080519060200190929190505050905090565b806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505056fea165627a7a723058209de47b3e814c56fb80861a580d360af8738753c53cc6e71163f687ed3eed570f0029"; - - public static final String FUNC_SET = "set"; - - public static final String FUNC_SIMPLESTORAGE = "simpleStorage"; - - public static final String FUNC_GET = "get"; - - public static final String FUNC_SETREMOTE = "setRemote"; - - @Deprecated - protected RemoteSimpleStorage( - String contractAddress, - Web3j web3j, - Credentials credentials, - BigInteger gasPrice, - BigInteger gasLimit) { - super(BINARY, contractAddress, web3j, credentials, gasPrice, gasLimit); - } - - protected RemoteSimpleStorage( - String contractAddress, - Web3j web3j, - Credentials credentials, - ContractGasProvider contractGasProvider) { - super(BINARY, contractAddress, web3j, credentials, contractGasProvider); - } - - @Deprecated - protected RemoteSimpleStorage( - String contractAddress, - Web3j web3j, - TransactionManager transactionManager, - BigInteger gasPrice, - BigInteger gasLimit) { - super(BINARY, contractAddress, web3j, transactionManager, gasPrice, gasLimit); - } - - protected RemoteSimpleStorage( - String contractAddress, - Web3j web3j, - TransactionManager transactionManager, - ContractGasProvider contractGasProvider) { - super(BINARY, contractAddress, web3j, transactionManager, contractGasProvider); - } - - public RemoteFunctionCall set(BigInteger value) { - final Function function = - new Function( - FUNC_SET, - Arrays.asList(new org.web3j.abi.datatypes.generated.Uint256(value)), - Collections.>emptyList()); - return executeRemoteCallTransaction(function); - } - - public RemoteFunctionCall simpleStorage() { - final Function function = - new Function( - FUNC_SIMPLESTORAGE, - Arrays.asList(), - Arrays.>asList(new TypeReference

() {})); - return executeRemoteCallSingleValueReturn(function, String.class); - } - - public RemoteFunctionCall get() { - final Function function = - new Function( - FUNC_GET, - Arrays.asList(), - Arrays.>asList(new TypeReference() {})); - return executeRemoteCallSingleValueReturn(function, BigInteger.class); - } - - public RemoteFunctionCall setRemote(String _simpleStorage) { - final Function function = - new Function( - FUNC_SETREMOTE, - Arrays.asList(new org.web3j.abi.datatypes.Address(160, _simpleStorage)), - Collections.>emptyList()); - return executeRemoteCallTransaction(function); - } - - @Deprecated - public static RemoteSimpleStorage load( - String contractAddress, - Web3j web3j, - Credentials credentials, - BigInteger gasPrice, - BigInteger gasLimit) { - return new RemoteSimpleStorage(contractAddress, web3j, credentials, gasPrice, gasLimit); - } - - @Deprecated - public static RemoteSimpleStorage load( - String contractAddress, - Web3j web3j, - TransactionManager transactionManager, - BigInteger gasPrice, - BigInteger gasLimit) { - return new RemoteSimpleStorage(contractAddress, web3j, transactionManager, gasPrice, gasLimit); - } - - public static RemoteSimpleStorage load( - String contractAddress, - Web3j web3j, - Credentials credentials, - ContractGasProvider contractGasProvider) { - return new RemoteSimpleStorage(contractAddress, web3j, credentials, contractGasProvider); - } - - public static RemoteSimpleStorage load( - String contractAddress, - Web3j web3j, - TransactionManager transactionManager, - ContractGasProvider contractGasProvider) { - return new RemoteSimpleStorage(contractAddress, web3j, transactionManager, contractGasProvider); - } - - public static RemoteCall deploy( - Web3j web3j, Credentials credentials, ContractGasProvider contractGasProvider) { - return deployRemoteCall( - RemoteSimpleStorage.class, web3j, credentials, contractGasProvider, BINARY, ""); - } - - @Deprecated - public static RemoteCall deploy( - Web3j web3j, Credentials credentials, BigInteger gasPrice, BigInteger gasLimit) { - return deployRemoteCall( - RemoteSimpleStorage.class, web3j, credentials, gasPrice, gasLimit, BINARY, ""); - } - - public static RemoteCall deploy( - Web3j web3j, TransactionManager transactionManager, ContractGasProvider contractGasProvider) { - return deployRemoteCall( - RemoteSimpleStorage.class, web3j, transactionManager, contractGasProvider, BINARY, ""); - } - - @Deprecated - public static RemoteCall deploy( - Web3j web3j, - TransactionManager transactionManager, - BigInteger gasPrice, - BigInteger gasLimit) { - return deployRemoteCall( - RemoteSimpleStorage.class, web3j, transactionManager, gasPrice, gasLimit, BINARY, ""); - } -} diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RevertReason.abi b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RevertReason.abi deleted file mode 100644 index e1bf8b0463..0000000000 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RevertReason.abi +++ /dev/null @@ -1 +0,0 @@ -[{"constant":true,"inputs":[],"name":"revertWithRevertReason","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"pure","type":"function"},{"constant":true,"inputs":[],"name":"revertWithoutRevertReason","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"pure","type":"function"}] \ No newline at end of file diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RevertReason.bin b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RevertReason.bin deleted file mode 100644 index 1848ca10c1..0000000000 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RevertReason.bin +++ /dev/null @@ -1 +0,0 @@ -608060405234801561001057600080fd5b5060d18061001f6000396000f3fe6080604052348015600f57600080fd5b506004361060325760003560e01c806311f95f6f146037578063ff489d31146051575b600080fd5b603d6057565b604080519115158252519081900360200190f35b603d6095565b6040805162461bcd60e51b815260206004820152600c60248201526b2932bb32b93a2932b0b9b7b760a11b6044820152905160009181900360640190fd5b6000806000fdfea265627a7a723058202dd24b599e57aa54899e1beceec3fb4a5001fccb4be994e8d18aa03cc123708764736f6c634300050a0032 \ No newline at end of file diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RevertReason.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RevertReason.java deleted file mode 100644 index 5fdea67f4b..0000000000 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/RevertReason.java +++ /dev/null @@ -1,175 +0,0 @@ -/* - * Copyright ConsenSys AG. - * - * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on - * an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the - * specific language governing permissions and limitations under the License. - * - * SPDX-License-Identifier: Apache-2.0 - */ -package org.hyperledger.besu.tests.web3j.generated; - -import java.math.BigInteger; -import java.util.Arrays; - -import org.web3j.abi.TypeReference; -import org.web3j.abi.datatypes.Bool; -import org.web3j.abi.datatypes.Function; -import org.web3j.abi.datatypes.Type; -import org.web3j.crypto.Credentials; -import org.web3j.protocol.Web3j; -import org.web3j.protocol.core.RemoteCall; -import org.web3j.tx.Contract; -import org.web3j.tx.TransactionManager; -import org.web3j.tx.gas.ContractGasProvider; - -/** - * Auto generated code. - * - *

Do not modify! - * - *

Please use the web3j command line tools, - * or the org.web3j.codegen.SolidityFunctionWrapperGenerator in the codegen module to update. - * - *

Generated with web3j version 4.3.0. - */ -@SuppressWarnings("rawtypes") -public class RevertReason extends Contract { - private static final String BINARY = - "608060405234801561001057600080fd5b5060d18061001f6000396000f3fe6080604052348015600f57600080fd5b506004361060325760003560e01c806311f95f6f146037578063ff489d31146051575b600080fd5b603d6057565b604080519115158252519081900360200190f35b603d6095565b6040805162461bcd60e51b815260206004820152600c60248201526b2932bb32b93a2932b0b9b7b760a11b6044820152905160009181900360640190fd5b6000806000fdfea265627a7a723058202dd24b599e57aa54899e1beceec3fb4a5001fccb4be994e8d18aa03cc123708764736f6c634300050a0032"; - - public static final String FUNC_REVERTWITHREVERTREASON = "revertWithRevertReason"; - - public static final String FUNC_REVERTWITHOUTREVERTREASON = "revertWithoutRevertReason"; - - @Deprecated - protected RevertReason( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final BigInteger gasPrice, - final BigInteger gasLimit) { - super(BINARY, contractAddress, web3j, credentials, gasPrice, gasLimit); - } - - protected RevertReason( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final ContractGasProvider contractGasProvider) { - super(BINARY, contractAddress, web3j, credentials, contractGasProvider); - } - - @Deprecated - protected RevertReason( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final BigInteger gasPrice, - final BigInteger gasLimit) { - super(BINARY, contractAddress, web3j, transactionManager, gasPrice, gasLimit); - } - - protected RevertReason( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final ContractGasProvider contractGasProvider) { - super(BINARY, contractAddress, web3j, transactionManager, contractGasProvider); - } - - public RemoteCall revertWithRevertReason() { - final Function function = - new Function( - FUNC_REVERTWITHREVERTREASON, - Arrays.asList(), - Arrays.>asList(new TypeReference() {})); - return executeRemoteCallSingleValueReturn(function, Boolean.class); - } - - public RemoteCall revertWithoutRevertReason() { - final Function function = - new Function( - FUNC_REVERTWITHOUTREVERTREASON, - Arrays.asList(), - Arrays.>asList(new TypeReference() {})); - return executeRemoteCallSingleValueReturn(function, Boolean.class); - } - - @Deprecated - public static RevertReason load( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return new RevertReason(contractAddress, web3j, credentials, gasPrice, gasLimit); - } - - @Deprecated - public static RevertReason load( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return new RevertReason(contractAddress, web3j, transactionManager, gasPrice, gasLimit); - } - - public static RevertReason load( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final ContractGasProvider contractGasProvider) { - return new RevertReason(contractAddress, web3j, credentials, contractGasProvider); - } - - public static RevertReason load( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final ContractGasProvider contractGasProvider) { - return new RevertReason(contractAddress, web3j, transactionManager, contractGasProvider); - } - - public static RemoteCall deploy( - final Web3j web3j, - final Credentials credentials, - final ContractGasProvider contractGasProvider) { - return deployRemoteCall( - RevertReason.class, web3j, credentials, contractGasProvider, BINARY, ""); - } - - @Deprecated - public static RemoteCall deploy( - final Web3j web3j, - final Credentials credentials, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return deployRemoteCall(RevertReason.class, web3j, credentials, gasPrice, gasLimit, BINARY, ""); - } - - public static RemoteCall deploy( - final Web3j web3j, - final TransactionManager transactionManager, - final ContractGasProvider contractGasProvider) { - return deployRemoteCall( - RevertReason.class, web3j, transactionManager, contractGasProvider, BINARY, ""); - } - - @Deprecated - public static RemoteCall deploy( - final Web3j web3j, - final TransactionManager transactionManager, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return deployRemoteCall( - RevertReason.class, web3j, transactionManager, gasPrice, gasLimit, BINARY, ""); - } -} diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/SimpleStorage.abi b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/SimpleStorage.abi deleted file mode 100644 index 4880337f3d..0000000000 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/SimpleStorage.abi +++ /dev/null @@ -1 +0,0 @@ -[{"constant":false,"inputs":[{"name":"value","type":"uint256"}],"name":"set","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"get","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"}] \ No newline at end of file diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/SimpleStorage.bin b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/SimpleStorage.bin deleted file mode 100644 index 60203ddfac..0000000000 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/SimpleStorage.bin +++ /dev/null @@ -1 +0,0 @@ -608060405234801561001057600080fd5b5060d08061001f6000396000f3fe60806040526004361060485763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166360fe47b18114604d5780636d4ce63c146075575b600080fd5b348015605857600080fd5b50607360048036036020811015606d57600080fd5b50356099565b005b348015608057600080fd5b506087609e565b60408051918252519081900360200190f35b600055565b6000549056fea165627a7a72305820cb1d0935d14b589300b12fcd0ab849a7e9019c81da24d6daa4f6b2f003d1b0180029 \ No newline at end of file diff --git a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/SimpleStorage.java b/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/SimpleStorage.java deleted file mode 100644 index 323bfc216b..0000000000 --- a/acceptance-tests/tests/src/test/java/org/hyperledger/besu/tests/web3j/generated/SimpleStorage.java +++ /dev/null @@ -1,178 +0,0 @@ -/* - * Copyright ConsenSys AG. - * - * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on - * an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the - * specific language governing permissions and limitations under the License. - * - * SPDX-License-Identifier: Apache-2.0 - */ -package org.hyperledger.besu.tests.web3j.generated; - -import java.math.BigInteger; -import java.util.Arrays; -import java.util.Collections; - -import org.web3j.abi.TypeReference; -import org.web3j.abi.datatypes.Function; -import org.web3j.abi.datatypes.Type; -import org.web3j.abi.datatypes.generated.Uint256; -import org.web3j.crypto.Credentials; -import org.web3j.protocol.Web3j; -import org.web3j.protocol.core.RemoteCall; -import org.web3j.protocol.core.methods.response.TransactionReceipt; -import org.web3j.tx.Contract; -import org.web3j.tx.TransactionManager; -import org.web3j.tx.gas.ContractGasProvider; - -/** - * Auto generated code. - * - *

Do not modify! - * - *

Please use the web3j command line tools, - * or the org.web3j.codegen.SolidityFunctionWrapperGenerator in the codegen module to update. - * - *

Generated with web3j version 4.0.1. - */ -@SuppressWarnings("rawtypes") -public class SimpleStorage extends Contract { - private static final String BINARY = - "608060405234801561001057600080fd5b5060d08061001f6000396000f3fe60806040526004361060485763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166360fe47b18114604d5780636d4ce63c146075575b600080fd5b348015605857600080fd5b50607360048036036020811015606d57600080fd5b50356099565b005b348015608057600080fd5b506087609e565b60408051918252519081900360200190f35b600055565b6000549056fea165627a7a72305820cb1d0935d14b589300b12fcd0ab849a7e9019c81da24d6daa4f6b2f003d1b0180029"; - - public static final String FUNC_SET = "set"; - - public static final String FUNC_GET = "get"; - - @Deprecated - protected SimpleStorage( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final BigInteger gasPrice, - final BigInteger gasLimit) { - super(BINARY, contractAddress, web3j, credentials, gasPrice, gasLimit); - } - - protected SimpleStorage( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final ContractGasProvider contractGasProvider) { - super(BINARY, contractAddress, web3j, credentials, contractGasProvider); - } - - @Deprecated - protected SimpleStorage( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final BigInteger gasPrice, - final BigInteger gasLimit) { - super(BINARY, contractAddress, web3j, transactionManager, gasPrice, gasLimit); - } - - protected SimpleStorage( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final ContractGasProvider contractGasProvider) { - super(BINARY, contractAddress, web3j, transactionManager, contractGasProvider); - } - - public RemoteCall set(final BigInteger value) { - final Function function = - new Function( - FUNC_SET, - Arrays.asList(new org.web3j.abi.datatypes.generated.Uint256(value)), - Collections.>emptyList()); - return executeRemoteCallTransaction(function); - } - - public RemoteCall get() { - final Function function = - new Function( - FUNC_GET, - Arrays.asList(), - Arrays.>asList(new TypeReference() {})); - return executeRemoteCallSingleValueReturn(function, BigInteger.class); - } - - @Deprecated - public static SimpleStorage load( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return new SimpleStorage(contractAddress, web3j, credentials, gasPrice, gasLimit); - } - - @Deprecated - public static SimpleStorage load( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return new SimpleStorage(contractAddress, web3j, transactionManager, gasPrice, gasLimit); - } - - public static SimpleStorage load( - final String contractAddress, - final Web3j web3j, - final Credentials credentials, - final ContractGasProvider contractGasProvider) { - return new SimpleStorage(contractAddress, web3j, credentials, contractGasProvider); - } - - public static SimpleStorage load( - final String contractAddress, - final Web3j web3j, - final TransactionManager transactionManager, - final ContractGasProvider contractGasProvider) { - return new SimpleStorage(contractAddress, web3j, transactionManager, contractGasProvider); - } - - public static RemoteCall deploy( - final Web3j web3j, - final Credentials credentials, - final ContractGasProvider contractGasProvider) { - return deployRemoteCall( - SimpleStorage.class, web3j, credentials, contractGasProvider, BINARY, ""); - } - - @Deprecated - public static RemoteCall deploy( - final Web3j web3j, - final Credentials credentials, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return deployRemoteCall( - SimpleStorage.class, web3j, credentials, gasPrice, gasLimit, BINARY, ""); - } - - public static RemoteCall deploy( - final Web3j web3j, - final TransactionManager transactionManager, - final ContractGasProvider contractGasProvider) { - return deployRemoteCall( - SimpleStorage.class, web3j, transactionManager, contractGasProvider, BINARY, ""); - } - - @Deprecated - public static RemoteCall deploy( - final Web3j web3j, - final TransactionManager transactionManager, - final BigInteger gasPrice, - final BigInteger gasLimit) { - return deployRemoteCall( - SimpleStorage.class, web3j, transactionManager, gasPrice, gasLimit, BINARY, ""); - } -}