-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
tests: Add initial bridge backend test.
- Loading branch information
Showing
1 changed file
with
37 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
use anyhow::bail; | ||
use async_trait::async_trait; | ||
|
||
use citrea_e2e::{ | ||
config::TestCaseConfig, | ||
framework::TestFramework, | ||
test_case::{TestCase, TestCaseRunner}, | ||
}; | ||
|
||
struct BasicBridgeBackendTest; | ||
|
||
#[async_trait] | ||
impl TestCase for BasicBridgeBackendTest { | ||
fn test_config() -> TestCaseConfig { | ||
TestCaseConfig { | ||
with_bridge_backend: true, | ||
with_sequencer: false, | ||
..Default::default() | ||
} | ||
} | ||
|
||
async fn run_test(&mut self, f: &mut TestFramework) -> citrea_e2e::Result<()> { | ||
let Some(_da) = f.bitcoin_nodes.get(0) else { | ||
bail!("bitcoind not running!") | ||
}; | ||
let Some(_bridge_backend) = f.bridge_backend_nodes.get(0) else { | ||
bail!("Bridge backend is not running!") | ||
}; | ||
|
||
Ok(()) | ||
} | ||
} | ||
|
||
#[tokio::test] | ||
async fn basic_prover_test() -> citrea_e2e::Result<()> { | ||
TestCaseRunner::new(BasicBridgeBackendTest).run().await | ||
} |