difftreelog
test fix unit tests
in: master
3 files changed
crates/evm-coder/tests/a.rsdiffbeforeafterboth--- a/crates/evm-coder/tests/a.rs
+++ b/crates/evm-coder/tests/a.rs
@@ -7,14 +7,14 @@
#[solidity_interface(name = "OurInterface")]
impl Impls {
- fn fn_a(&self, input: uint256) -> Result<bool> {
+ fn fn_a(&self, _input: uint256) -> Result<bool> {
todo!()
}
}
#[solidity_interface(name = "OurInterface1")]
impl Impls {
- fn fn_b(&self, input: uint128) -> Result<uint32> {
+ fn fn_b(&self, _input: uint128) -> Result<uint32> {
todo!()
}
}
@@ -27,17 +27,17 @@
)]
impl Impls {
#[solidity(rename_selector = "fnK")]
- fn fn_c(&self, input: uint32) -> Result<uint8> {
+ fn fn_c(&self, _input: uint32) -> Result<uint8> {
todo!()
}
- fn fn_d(&self, value: uint32) -> Result<uint32> {
+ fn fn_d(&self, _value: uint32) -> Result<uint32> {
todo!()
}
- fn caller_sensitive(&self, caller: caller) -> Result<uint8> {
+ fn caller_sensitive(&self, _caller: caller) -> Result<uint8> {
todo!()
}
- fn payable(&mut self, value: value) -> Result<uint8> {
+ fn payable(&mut self, _value: value) -> Result<uint8> {
todo!()
}
}
@@ -65,25 +65,25 @@
fn decimals(&self) -> Result<uint8> {
todo!()
}
- fn balance_of(&self, owner: address) -> Result<uint256> {
+ fn balance_of(&self, _owner: address) -> Result<uint256> {
todo!()
}
- fn transfer(&mut self, caller: caller, to: address, value: uint256) -> Result<bool> {
+ fn transfer(&mut self, _caller: caller, _to: address, _value: uint256) -> Result<bool> {
todo!()
}
fn transfer_from(
&mut self,
- caller: caller,
- from: address,
- to: address,
- value: uint256,
+ _caller: caller,
+ _from: address,
+ _to: address,
+ _value: uint256,
) -> Result<bool> {
todo!()
}
- fn approve(&mut self, caller: caller, spender: address, value: uint256) -> Result<bool> {
+ fn approve(&mut self, _caller: caller, _spender: address, _value: uint256) -> Result<bool> {
todo!()
}
- fn allowance(&self, owner: address, spender: address) -> Result<uint256> {
+ fn allowance(&self, _owner: address, _spender: address) -> Result<uint256> {
todo!()
}
}
pallets/evm-coder-substrate/src/lib.rsdiffbeforeafterboth38 }38 }393940 #[pallet::config]40 #[pallet::config]41 pub trait Config: frame_system::Config + pallet_evm::Config {41 pub trait Config: frame_system::Config {42 type EthereumTransactionSender: pallet_ethereum::EthereumTransactionSender;42 type EthereumTransactionSender: pallet_ethereum::EthereumTransactionSender;43 }43 }4444pallets/nft/src/mock.rsdiffbeforeafterboth--- a/pallets/nft/src/mock.rs
+++ b/pallets/nft/src/mock.rs
@@ -6,7 +6,6 @@
use sp_runtime::{
traits::{BlakeTwo256, IdentityLookup},
testing::Header,
- Perbill,
};
use pallet_transaction_payment::{CurrencyAdapter};
use frame_system as system;
@@ -99,9 +98,6 @@
type WeightInfo = ();
}
-type Timestamp = pallet_timestamp::Pallet<Test>;
-type Randomness = pallet_randomness_collective_flip::Pallet<Test>;
-
parameter_types! {
pub const CollectionCreationPrice: u32 = 0;
pub TreasuryAccountId: u64 = 1234;
@@ -151,6 +147,10 @@
}
}
+impl pallet_evm_coder_substrate::Config for Test {
+ type EthereumTransactionSender = TestEtheremTransactionSender;
+}
+
impl pallet_template::Config for Test {
type Event = ();
type WeightInfo = ();
@@ -160,7 +160,6 @@
type EvmAddressMapping = TestEvmAddressMapping;
type EvmBackwardsAddressMapping = TestEvmBackwardsAddressMapping;
type CrossAccountId = TestCrossAccountId;
- type EthereumTransactionSender = TestEtheremTransactionSender;
}
// Build genesis storage according to the mock runtime.