tests/nixos/fetch-git: Make the store paths unique

This commit is contained in:
Robert Hensing 2024-01-18 20:56:33 +01:00
parent 94eba0ebbb
commit 1254170405
2 changed files with 8 additions and 4 deletions

View File

@ -1,10 +1,12 @@
{ config, ... }:
{
description = "can fetch a git repo via http";
script = ''
# add a file to the repo
client.succeed(f"""
echo chiang-mai > {repo.path}/thailand \
&& {repo.git} add thailand \
echo ${config.name /* to make the git tree and store path unique */} > {repo.path}/test-case \
&& echo chiang-mai > {repo.path}/thailand \
&& {repo.git} add test-case thailand \
&& {repo.git} commit -m 'commit1'
""")

View File

@ -1,10 +1,12 @@
{ config, ... }:
{
description = "can fetch a git repo via ssh";
script = ''
# add a file to the repo
client.succeed(f"""
echo chiang-mai > {repo.path}/thailand \
&& {repo.git} add thailand \
echo ${config.name /* to make the git tree and store path unique */} > {repo.path}/test-case \
&& echo chiang-mai > {repo.path}/thailand \
&& {repo.git} add test-case thailand \
&& {repo.git} commit -m 'commit1'
""")