vdev/commands/e2e/stop.rs
1use anyhow::Result;
2use clap::Args;
3
4use crate::testing::integration::ComposeTestLocalConfig;
5
6/// Stop an e2e-test environment
7#[derive(Args, Debug)]
8#[command()]
9pub struct Cli {
10 /// The e2e test name to stop
11 test: String,
12
13 /// If true, remove the runner container compiled with all integration test features
14 #[arg(short = 'a', long)]
15 build_all: bool,
16
17 /// Reuse existing test runner image instead of rebuilding (useful in CI)
18 #[arg(long)]
19 reuse_image: bool,
20}
21
22impl Cli {
23 pub fn exec(self) -> Result<()> {
24 crate::commands::compose_tests::stop::exec(
25 ComposeTestLocalConfig::e2e(),
26 &self.test,
27 self.build_all,
28 self.reuse_image,
29 )
30 }
31}