mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-31 14:31:02 +00:00
Disable cache in CI builds. (#772)
* Disable cache. * Fix tests. * Fix clippy? * cargo fmt --all
This commit is contained in:
committed by
Bastian Köcher
parent
de5ac085a1
commit
7602d910d4
@@ -369,9 +369,9 @@ mod tests {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Can still submit `MaxRequests` requests afterwards
|
// Can still submit `MaxRequests` requests afterwards
|
||||||
assert_ok!(submit_finality_proof());
|
assert_ok!(submit_finality_proof(1, 2));
|
||||||
assert_ok!(submit_finality_proof());
|
assert_ok!(submit_finality_proof(3, 4));
|
||||||
assert_err!(submit_finality_proof(), <Error<TestRuntime>>::TooManyRequests);
|
assert_err!(submit_finality_proof(5, 6), <Error<TestRuntime>>::TooManyRequests);
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -243,16 +243,13 @@ fn ethereum_deploy_contract_params(matches: &clap::ArgMatches) -> Result<Ethereu
|
|||||||
let eth_contract_code = parse_hex_argument(matches, "eth-contract-code")?.unwrap_or_else(|| {
|
let eth_contract_code = parse_hex_argument(matches, "eth-contract-code")?.unwrap_or_else(|| {
|
||||||
hex::decode(include_str!("../res/substrate-bridge-bytecode.hex")).expect("code is hardcoded, thus valid; qed")
|
hex::decode(include_str!("../res/substrate-bridge-bytecode.hex")).expect("code is hardcoded, thus valid; qed")
|
||||||
});
|
});
|
||||||
|
let sub_initial_authorities_set_id = matches
|
||||||
#[allow(clippy::manual_map)]
|
.value_of("sub-authorities-set-id")
|
||||||
let sub_initial_authorities_set_id = match matches.value_of("sub-authorities-set-id") {
|
.map(|set| {
|
||||||
Some(sub_initial_authorities_set_id) => Some(
|
set.parse()
|
||||||
sub_initial_authorities_set_id
|
.map_err(|e| format!("Failed to parse sub-authorities-set-id: {}", e))
|
||||||
.parse()
|
})
|
||||||
.map_err(|e| format!("Failed to parse sub-authorities-set-id: {}", e))?,
|
.transpose()?;
|
||||||
),
|
|
||||||
None => None,
|
|
||||||
};
|
|
||||||
let sub_initial_authorities_set = parse_hex_argument(matches, "sub-authorities-set")?;
|
let sub_initial_authorities_set = parse_hex_argument(matches, "sub-authorities-set")?;
|
||||||
let sub_initial_header = parse_hex_argument(matches, "sub-initial-header")?;
|
let sub_initial_header = parse_hex_argument(matches, "sub-initial-header")?;
|
||||||
|
|
||||||
@@ -272,24 +269,26 @@ fn ethereum_deploy_contract_params(matches: &clap::ArgMatches) -> Result<Ethereu
|
|||||||
}
|
}
|
||||||
|
|
||||||
fn ethereum_exchange_submit_params(matches: &clap::ArgMatches) -> Result<EthereumExchangeSubmitParams, String> {
|
fn ethereum_exchange_submit_params(matches: &clap::ArgMatches) -> Result<EthereumExchangeSubmitParams, String> {
|
||||||
#[allow(clippy::manual_map)]
|
let eth_nonce = matches
|
||||||
let eth_nonce = if let Some(eth_nonce) = matches.value_of("eth-nonce") {
|
.value_of("eth-nonce")
|
||||||
Some(
|
.map(|eth_nonce| {
|
||||||
relay_ethereum_client::types::U256::from_dec_str(ð_nonce)
|
relay_ethereum_client::types::U256::from_dec_str(ð_nonce)
|
||||||
.map_err(|e| format!("Failed to parse eth-nonce: {}", e))?,
|
.map_err(|e| format!("Failed to parse eth-nonce: {}", e))
|
||||||
)
|
})
|
||||||
} else {
|
.transpose()?;
|
||||||
None
|
|
||||||
};
|
|
||||||
|
|
||||||
let eth_amount = if let Some(eth_amount) = matches.value_of("eth-amount") {
|
let eth_amount = matches
|
||||||
eth_amount
|
.value_of("eth-amount")
|
||||||
.parse()
|
.map(|eth_amount| {
|
||||||
.map_err(|e| format!("Failed to parse eth-amount: {}", e))?
|
eth_amount
|
||||||
} else {
|
.parse()
|
||||||
// This is in Wei, represents 1 ETH
|
.map_err(|e| format!("Failed to parse eth-amount: {}", e))
|
||||||
1_000_000_000_000_000_000_u64.into()
|
})
|
||||||
};
|
.transpose()?
|
||||||
|
.unwrap_or_else(|| {
|
||||||
|
// This is in Wei, represents 1 ETH
|
||||||
|
1_000_000_000_000_000_000_u64.into()
|
||||||
|
});
|
||||||
|
|
||||||
// This is the well-known Substrate account of Ferdie
|
// This is the well-known Substrate account of Ferdie
|
||||||
let default_recepient = hex!("1cbd2d43530a44705ad088af313e18f80b53ef16b36177cd4b77b846f2a5f07c");
|
let default_recepient = hex!("1cbd2d43530a44705ad088af313e18f80b53ef16b36177cd4b77b846f2a5f07c");
|
||||||
@@ -332,15 +331,16 @@ fn ethereum_exchange_params(matches: &clap::ArgMatches) -> Result<EthereumExchan
|
|||||||
.parse()
|
.parse()
|
||||||
.map_err(|e| format!("Failed to parse eth-tx-hash: {}", e))?,
|
.map_err(|e| format!("Failed to parse eth-tx-hash: {}", e))?,
|
||||||
),
|
),
|
||||||
#[allow(clippy::manual_map)]
|
None => ethereum_exchange::ExchangeRelayMode::Auto(
|
||||||
None => ethereum_exchange::ExchangeRelayMode::Auto(match matches.value_of("eth-start-with-block") {
|
matches
|
||||||
Some(eth_start_with_block) => Some(
|
.value_of("eth-start-with-block")
|
||||||
eth_start_with_block
|
.map(|eth_start_with_block| {
|
||||||
.parse()
|
eth_start_with_block
|
||||||
.map_err(|e| format!("Failed to parse eth-start-with-block: {}", e))?,
|
.parse()
|
||||||
),
|
.map_err(|e| format!("Failed to parse eth-start-with-block: {}", e))
|
||||||
None => None,
|
})
|
||||||
}),
|
.transpose()?,
|
||||||
|
),
|
||||||
};
|
};
|
||||||
|
|
||||||
let params = EthereumExchangeParams {
|
let params = EthereumExchangeParams {
|
||||||
|
|||||||
Reference in New Issue
Block a user