mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 23:57:56 +00:00
Introduce new testnet ready for 0.10 (#1677)
* Introduce new testnet ready for 0.10 * Upgraded dd spec
This commit is contained in:
committed by
Arkadiy Paronyan
parent
bd89003e43
commit
c3e6572886
@@ -32,9 +32,9 @@ const STAGING_TELEMETRY_URL: &str = "wss://telemetry.polkadot.io/submit/";
|
||||
/// Specialised `ChainSpec`.
|
||||
pub type ChainSpec = substrate_service::ChainSpec<GenesisConfig>;
|
||||
|
||||
/// Charred Cherry testnet generator
|
||||
pub fn charred_cherry_config() -> Result<ChainSpec, String> {
|
||||
ChainSpec::from_embedded(include_bytes!("../res/charred-cherry.json"))
|
||||
/// Dried Danta testnet generator
|
||||
pub fn dried_danta_config() -> Result<ChainSpec, String> {
|
||||
ChainSpec::from_embedded(include_bytes!("../res/dried-danta.json"))
|
||||
}
|
||||
|
||||
fn staging_testnet_config_genesis() -> GenesisConfig {
|
||||
|
||||
@@ -37,8 +37,8 @@ pub enum ChainSpec {
|
||||
Development,
|
||||
/// Whatever the current runtime is, with simple Alice/Bob auths.
|
||||
LocalTestnet,
|
||||
/// The Charred Cherry testnet.
|
||||
CharredCherry,
|
||||
/// The Dried Danta testnet.
|
||||
DriedDanta,
|
||||
/// Whatever the current runtime is with the "global testnet" defaults.
|
||||
StagingTestnet,
|
||||
}
|
||||
@@ -47,7 +47,7 @@ pub enum ChainSpec {
|
||||
impl ChainSpec {
|
||||
pub(crate) fn load(self) -> Result<chain_spec::ChainSpec, String> {
|
||||
Ok(match self {
|
||||
ChainSpec::CharredCherry => chain_spec::charred_cherry_config()?,
|
||||
ChainSpec::DriedDanta => chain_spec::dried_danta_config()?,
|
||||
ChainSpec::Development => chain_spec::development_config(),
|
||||
ChainSpec::LocalTestnet => chain_spec::local_testnet_config(),
|
||||
ChainSpec::StagingTestnet => chain_spec::staging_testnet_config(),
|
||||
@@ -58,7 +58,7 @@ impl ChainSpec {
|
||||
match s {
|
||||
"dev" => Some(ChainSpec::Development),
|
||||
"local" => Some(ChainSpec::LocalTestnet),
|
||||
"" | "cherry" | "charred-cherry" => Some(ChainSpec::CharredCherry),
|
||||
"" | "danta" | "dried-danta" => Some(ChainSpec::DriedDanta),
|
||||
"staging" => Some(ChainSpec::StagingTestnet),
|
||||
_ => None,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user