Skip to content
Snippets Groups Projects

split one test into three

Merged Hans Fangohr requested to merge split-installation-tests into force-checking-of-error-code
2 files
+ 10
7
Compare changes
  • Side-by-side
  • Inline
Files
2
@@ -258,14 +258,15 @@ def create_dir_structure(mpsd_release: str, script_dir: Path) -> None:
with os_chdir("spack-environments"):
# Git fetch and checkout the release branch and git pull
# to be sure that the resulting repo is up to date
run(["git", "fetch", "--all"])
checkout_result = run(["git", "checkout", mpsd_release])
run(["git", "fetch", "--all"], check=True)
checkout_result = run(["git", "checkout", mpsd_release], check=True)
if checkout_result.returncode != 0:
raise Exception(
"Release branch does not exist in spack-environment repo \n."
"Check for typos."
)
run(["git", "pull"])
run(["git", "pull"], check=True)
def get_release_info(mpsd_release: str, script_dir: Path) -> Tuple[str, str, List[str]]:
@@ -306,13 +307,15 @@ def get_release_info(mpsd_release: str, script_dir: Path) -> Tuple[str, str, Lis
with os_chdir("spack-environments"):
# Get the branch and commit hash of the spack-environments repo
spe_commit_hash = (
run(["git", "rev-parse", "HEAD"], stdout=subprocess.PIPE)
run(["git", "rev-parse", "HEAD"], stdout=subprocess.PIPE, check=True)
.stdout.decode()
.strip()
)
spe_branch = (
run(
["git", "rev-parse", "--abbrev-ref", "HEAD"], stdout=subprocess.PIPE
["git", "rev-parse", "--abbrev-ref", "HEAD"],
stdout=subprocess.PIPE,
check=True,
)
.stdout.decode()
.strip()
Loading