Skip to content

Commit

Permalink
Add show jobs test.
Browse files Browse the repository at this point in the history
  • Loading branch information
joaander committed Dec 5, 2024
1 parent 8a4137d commit 2616e20
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions tests/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -894,3 +894,25 @@ fn init() -> Result<(), Box<dyn std::error::Error>> {

Ok(())
}

#[test]
#[parallel]
fn show_jobs() -> Result<(), Box<dyn std::error::Error>> {
let temp = TempDir::new()?;
let _ = setup_sample_workflow(&temp, 4);

Command::cargo_bin("row")?
.args(["show", "jobs"])
.args(["--cluster", "none"])
.env_remove("ROW_COLOR")
.env_remove("CLICOLOR")
.env("ROW_HOME", "/not/a/path")
.current_dir(temp.path())
.assert()
.success();

// It is not possible to automatically check the output of show jobs. This unit test
// must run on systems that do not have SLURM or where developers have no SLURM account.

Ok(())
}

0 comments on commit 2616e20

Please sign in to comment.