summaryrefslogtreecommitdiff
path: root/tests/store.scm
diff options
context:
space:
mode:
authorLiliana Marie Prikler <[email protected]>2023-12-18 03:58:23 +0100
committerLiliana Marie Prikler <[email protected]>2023-12-18 03:58:23 +0100
commit256d5b3598fa2162e9712fc98781d2cb4ceda31e (patch)
tree0e7f7051a59aad879561b5c4ee885e24d3c04bc6 /tests/store.scm
parent9f6210cc5c114310a38ad1cc0ff5900409a7e7cc (diff)
parent1a9f267f51f97b8ca7049aa72763ddd64aad5b62 (diff)
Merge branch 'master' into wip-webkit
Diffstat (limited to 'tests/store.scm')
-rw-r--r--tests/store.scm25
1 files changed, 23 insertions, 2 deletions
diff --git a/tests/store.scm b/tests/store.scm
index 5df28adf0d..45948f4f43 100644
--- a/tests/store.scm
+++ b/tests/store.scm
@@ -1,5 +1,5 @@
;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Ludovic Courtès <[email protected]>
+;;; Copyright © 2012-2021, 2023 Ludovic Courtès <[email protected]>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -105,7 +105,28 @@
"/283gqy39v3g9dxjy26rynl0zls82fmcg-guile-2.0.7/bin/guile")))
(not (direct-store-path? (%store-prefix)))))
-(test-skip (if %store 0 15))
+(test-skip (if %store 0 18))
+
+(test-equal "substitute-urls, default"
+ (list (getenv "GUIX_BINARY_SUBSTITUTE_URL"))
+ (with-store store
+ (set-build-options store #:use-substitutes? #t)
+ (substitute-urls store)))
+
+(test-equal "substitute-urls, client-specified URLs"
+ '("http://substitutes.example.org"
+ "http://other.example.org")
+ (with-store store
+ (set-build-options store #:use-substitutes? #t
+ #:substitute-urls '("http://substitutes.example.org"
+ "http://other.example.org"))
+ (substitute-urls store)))
+
+(test-equal "substitute-urls, disabled"
+ '()
+ (with-store store
+ (set-build-options store #:use-substitutes? #f)
+ (substitute-urls store)))
(test-equal "profiles/per-user exists and is not writable"
#o755