aboutsummaryrefslogtreecommitdiff
path: root/nixpkgs/pkgs/tools/misc/ostree/fix-test-paths.patch
blob: 3e5b7e06999e8fd51769eec4b0261b488dd37960 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
diff --git a/tests/libtest.sh b/tests/libtest.sh
index ca457fa2..c0a529ff 100755
--- a/tests/libtest.sh
+++ b/tests/libtest.sh
@@ -709,12 +709,12 @@ gen_ed25519_keys ()
 {
   # Generate private key in PEM format
   pemfile="$(mktemp -p ${test_tmpdir} ed25519_XXXXXX.pem)"
-  openssl genpkey -algorithm ed25519 -outform PEM -out "${pemfile}"
+  @openssl@ genpkey -algorithm ed25519 -outform PEM -out "${pemfile}"
 
   # Based on: http://openssl.6102.n7.nabble.com/ed25519-key-generation-td73907.html
   # Extract the private and public parts from generated key.
-  ED25519PUBLIC="$(openssl pkey -outform DER -pubout -in ${pemfile} | tail -c 32 | base64)"
-  ED25519SEED="$(openssl pkey -outform DER -in ${pemfile} | tail -c 32 | base64)"
+  ED25519PUBLIC="$(@openssl@ pkey -outform DER -pubout -in ${pemfile} | tail -c 32 | base64)"
+  ED25519SEED="$(@openssl@ pkey -outform DER -in ${pemfile} | tail -c 32 | base64)"
   # Secret key is concantination of SEED and PUBLIC
   ED25519SECRET="$(echo ${ED25519SEED}${ED25519PUBLIC} | base64 -d | base64 -w 0)"
 
@@ -725,7 +725,7 @@ gen_ed25519_keys ()
 
 gen_ed25519_random_public()
 {
-  openssl genpkey -algorithm ED25519 | openssl pkey -outform DER | tail -c 32 | base64
+  @openssl@ genpkey -algorithm ED25519 | @openssl@ pkey -outform DER | tail -c 32 | base64
 }
 
 is_bare_user_only_repo () {
diff --git a/tests/test-basic-user-only.sh b/tests/test-basic-user-only.sh
index f65094fd..105be893 100755
--- a/tests/test-basic-user-only.sh
+++ b/tests/test-basic-user-only.sh
@@ -29,7 +29,7 @@ extra_basic_tests=5
 . $(dirname $0)/basic-test.sh
 
 $CMD_PREFIX ostree --version > version.yaml
-python3 -c 'import yaml; yaml.safe_load(open("version.yaml"))'
+@python3@ -c 'import yaml; yaml.safe_load(open("version.yaml"))'
 echo "ok yaml version"
 
 # Reset things so we don't inherit a lot of state from earlier tests
diff --git a/tests/test-remote-headers.sh b/tests/test-remote-headers.sh
index a41d087a..77b34c90 100755
--- a/tests/test-remote-headers.sh
+++ b/tests/test-remote-headers.sh
@@ -26,7 +26,7 @@ echo '1..2'
 . $(dirname $0)/libtest.sh
 
 V=$($CMD_PREFIX ostree --version | \
-  python3 -c 'import sys, yaml; print(yaml.safe_load(sys.stdin)["libostree"]["Version"])')
+  @python3@ -c 'import sys, yaml; print(yaml.safe_load(sys.stdin)["libostree"]["Version"])')
 
 setup_fake_remote_repo1 "archive" "" \
   --expected-header foo=bar \