chore: fix lints / solc test

This commit is contained in:
Georgios Konstantopoulos 2022-01-11 12:13:09 +02:00
parent c95c12e0d1
commit 19671e51de
2 changed files with 26 additions and 26 deletions

View File

@ -60,25 +60,25 @@ impl TryFrom<u64> for Chain {
type Error = ParseChainError;
fn try_from(chain: u64) -> Result<Chain, Self::Error> {
match chain {
1 => Ok(Chain::Mainnet),
3 => Ok(Chain::Ropsten),
4 => Ok(Chain::Rinkeby),
5 => Ok(Chain::Goerli),
42 => Ok(Chain::Kovan),
100 => Ok(Chain::XDai),
137 => Ok(Chain::Polygon),
80001 => Ok(Chain::PolygonMumbai),
43114 => Ok(Chain::Avalanche),
43113 => Ok(Chain::AvalancheFuji),
11155111 => Ok(Chain::Sepolia),
1287 => Ok(Chain::Moonbeam),
1281 => Ok(Chain::MoonbeamDev),
1285 => Ok(Chain::Moonriver),
10 => Ok(Chain::Optimism),
69 => Ok(Chain::OptimismKovan),
Ok(match chain {
1 => Chain::Mainnet,
3 => Chain::Ropsten,
4 => Chain::Rinkeby,
5 => Chain::Goerli,
42 => Chain::Kovan,
100 => Chain::XDai,
137 => Chain::Polygon,
80001 => Chain::PolygonMumbai,
43114 => Chain::Avalanche,
43113 => Chain::AvalancheFuji,
11155111 => Chain::Sepolia,
1287 => Chain::Moonbeam,
1281 => Chain::MoonbeamDev,
1285 => Chain::Moonriver,
10 => Chain::Optimism,
69 => Chain::OptimismKovan,
_ => return Err(ParseChainError(chain.to_string())),
}
})
}
}

View File

@ -268,10 +268,10 @@ fn can_compile_dapp_sample_with_cache() {
assert_eq!(
compiled.into_artifacts().map(|(name, _)| name).collect::<Vec<_>>(),
vec![
r#"Dapp.json:Dapp"#,
r#"DappTest.json:DappTest"#,
r#"DSTest.json:DSTest"#,
"NewContract"
"Dapp.json:Dapp",
"DappTest.json:DappTest",
"DSTest.json:DSTest",
"NewContract.json:NewContract"
]
);
@ -281,10 +281,10 @@ fn can_compile_dapp_sample_with_cache() {
assert_eq!(
compiled.into_artifacts().map(|(name, _)| name).collect::<Vec<_>>(),
vec![
r#"DappTest.json:DappTest"#,
r#"NewContract.json:NewContract"#,
r#"DSTest.json:DSTest"#,
"Dapp"
"DappTest.json:DappTest",
"NewContract.json:NewContract",
"DSTest.json:DSTest",
"Dapp.json:Dapp"
]
);