mirror of
https://github.com/pezkuwichain/revive-differential-tests.git
synced 2026-06-19 09:51:04 +00:00
[WIP] - Impl EthereumNode for zombie node
This commit is contained in:
@@ -88,6 +88,15 @@ impl AsRef<KurtosisConfiguration> for Context {
|
||||
}
|
||||
}
|
||||
|
||||
impl AsRef<ZombieNetConfiguration> for Context {
|
||||
fn as_ref(&self) -> &ZombieNetConfiguration {
|
||||
match self {
|
||||
Self::ExecuteTests(context) => context.as_ref().as_ref(),
|
||||
Self::ExportJsonSchema => unreachable!(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl AsRef<KitchensinkConfiguration> for Context {
|
||||
fn as_ref(&self) -> &KitchensinkConfiguration {
|
||||
match self {
|
||||
@@ -195,6 +204,10 @@ pub struct TestExecutionContext {
|
||||
#[clap(flatten, next_help_heading = "Resolc Configuration")]
|
||||
pub resolc_configuration: ResolcConfiguration,
|
||||
|
||||
/// Configuration parameters for the Zombienet.
|
||||
#[clap(flatten, next_help_heading = "Zombienet Configuration")]
|
||||
pub zombienet_configuration: ZombieNetConfiguration,
|
||||
|
||||
/// Configuration parameters for the geth node.
|
||||
#[clap(flatten, next_help_heading = "Geth Configuration")]
|
||||
pub geth_configuration: GethConfiguration,
|
||||
@@ -266,6 +279,12 @@ impl AsRef<GethConfiguration> for TestExecutionContext {
|
||||
}
|
||||
}
|
||||
|
||||
impl AsRef<ZombieNetConfiguration> for TestExecutionContext {
|
||||
fn as_ref(&self) -> &ZombieNetConfiguration {
|
||||
&self.zombienet_configuration
|
||||
}
|
||||
}
|
||||
|
||||
impl AsRef<KurtosisConfiguration> for TestExecutionContext {
|
||||
fn as_ref(&self) -> &KurtosisConfiguration {
|
||||
&self.lighthouse_configuration
|
||||
@@ -340,6 +359,34 @@ pub struct ResolcConfiguration {
|
||||
pub path: PathBuf,
|
||||
}
|
||||
|
||||
/// A set of configuration parameters for Zombienet.
|
||||
#[derive(Clone, Debug, Parser, Serialize)]
|
||||
pub struct ZombieNetConfiguration {
|
||||
/// Specifies the path of the zombienet node to be used by the tool.
|
||||
///
|
||||
/// If this is not specified, then the tool assumes that it should use the zombienet binary
|
||||
/// that's provided in the user's $PATH.
|
||||
#[clap(
|
||||
id = "zombienet.path",
|
||||
long = "zombienet.path",
|
||||
default_value = "polkadot-parachain"
|
||||
)]
|
||||
pub path: PathBuf,
|
||||
|
||||
/// The amount of time to wait upon startup before considering that the node timed out.
|
||||
#[clap(
|
||||
id = "zombienet.start-timeout-ms",
|
||||
long = "zombienet.start-timeout-ms",
|
||||
default_value = "5000",
|
||||
value_parser = parse_duration
|
||||
)]
|
||||
pub start_timeout_ms: Duration,
|
||||
|
||||
/// This configures the tool to use Zombienet instead of using the revive-dev-node.
|
||||
#[clap(long = "zombienet.dont-use-dev-node")]
|
||||
pub use_zombienet: bool,
|
||||
}
|
||||
|
||||
/// A set of configuration parameters for Geth.
|
||||
#[derive(Clone, Debug, Parser, Serialize)]
|
||||
pub struct GethConfiguration {
|
||||
@@ -692,4 +739,6 @@ pub enum TestingPlatform {
|
||||
Geth,
|
||||
/// The kitchensink runtime provides the PolkaVM (PVM) based node implementation.
|
||||
Kitchensink,
|
||||
/// A polkadot/Substrate based network
|
||||
ZombieNet,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user