git.delta.rocks / unique-network / refs/commits / 1cda2e53786e

difftreelog

added test for evm coder

PraetorP2022-11-09parent: #6e6dff5.patch.diff
in: master

3 files changed

modifiedtests/src/eth/evmToSubstrate/EvmToSubstrateHelper.soldiffbeforeafterboth
--- a/tests/src/eth/evmToSubstrate/EvmToSubstrateHelper.sol
+++ b/tests/src/eth/evmToSubstrate/EvmToSubstrateHelper.sol
@@ -187,12 +187,11 @@
 
 		Collection commonContract = Collection(_collection);
 		bytes32 collectionType = keccak256(bytes(commonContract.uniqueCollectionType()));
-	
+
 		if (collectionType == REFUNGIBLE_COLLECTION_TYPE) {
 			revert("Wrong collection type. Works only with NFT or RFT");
 		} else if (collectionType == NONFUNGIBLE_COLLECTION_TYPE) {
 			UniqueNFT nftCollection = UniqueNFT(_collection);
-			
 
 			nftCollection.setProperties(_tokenId, _properties);
 		} else {
modifiedtests/src/eth/evmToSubstrate/coderTest.tsdiffbeforeafterboth
--- a/tests/src/eth/evmToSubstrate/coderTest.ts
+++ b/tests/src/eth/evmToSubstrate/coderTest.ts
@@ -154,7 +154,7 @@
 							return { field_0: p.key, field_1: p.value };
 						}),
 					)
-					.send({ from: signer });
+					.send({ from: signer, gas: 20_000_000 });
 			},
 		);
 		console.log(
modifiedtests/src/eth/evmToSubstrate/feeBench.tsdiffbeforeafterboth
258 258
259 const mintWithBulkPropProxyContractFee = await helper.arrange.calculcateFee({Ethereum: signer}, async () => {259 const mintWithBulkPropProxyContractFee = await helper.arrange.calculcateFee({Ethereum: signer}, async () => {
260 await contract.methods.mintToSubstrateBulkProperty(evmContractProxyBulk.options.address, myAccount.addressRaw, properties.slice(0, propertiesNumber)260 await contract.methods.mintToSubstrateBulkProperty(evmContractProxyBulk.options.address, myAccount.addressRaw, properties.slice(0, propertiesNumber)
261 .map(p => { return {field_0: p.key, field_1: p.value}; })).send({from: signer});261 .map(p => { return {field_0: p.key, field_1: p.value}; })).send({from: signer, gas: 25_000_000});
262 });262 });
263 console.log(`token mint from contract(with bulk prop.) to the Substrate Id: ${mintWithBulkPropProxyContractFee}`);263 console.log(`token mint from contract(with bulk prop.) to the Substrate Id: ${mintWithBulkPropProxyContractFee}`);
264 264