aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/gremlin.scm12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/gremlin.scm b/tests/gremlin.scm
index 225a72ff9f..dc9f78c21a 100644
--- a/tests/gremlin.scm
+++ b/tests/gremlin.scm
@@ -21,6 +21,7 @@
#:use-module (guix build utils)
#:use-module (guix build gremlin)
#:use-module (srfi srfi-1)
+ #:use-module (srfi srfi-26)
#:use-module (srfi srfi-64)
#:use-module (rnrs io ports)
#:use-module (ice-9 match))
@@ -51,6 +52,17 @@
(string-take lib (string-contains lib ".so")))
(elf-dynamic-info-needed dyninfo))))))
+(test-equal "expand-origin"
+ '("OOO/../lib"
+ "OOO"
+ "../OOO/bar/OOO/baz"
+ "ORIGIN/foo")
+ (map (cut expand-origin <> "OOO")
+ '("$ORIGIN/../lib"
+ "${ORIGIN}"
+ "../${ORIGIN}/bar/$ORIGIN/baz"
+ "ORIGIN/foo")))
+
(test-end "gremlin")