summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorMarius Bakke <mbakke@fastmail.com>2020-03-04 23:16:17 +0100
committerMarius Bakke <mbakke@fastmail.com>2020-03-04 23:16:17 +0100
commitebb7cf9e21060105d9950dd5142c0eb918083666 (patch)
tree36c1607b80d92e27fb9d09029d1d3b57a1fd5065 /tests
parent0b870f7915f5da43758753fd088a22033936dc50 (diff)
parentc2d7e800e6788277bc56f31d5836f9d507dc1506 (diff)
downloadguix-patches-ebb7cf9e21060105d9950dd5142c0eb918083666.tar
guix-patches-ebb7cf9e21060105d9950dd5142c0eb918083666.tar.gz
Merge branch 'master' into core-updates
Diffstat (limited to 'tests')
-rw-r--r--tests/swh.scm10
-rw-r--r--tests/ui.scm6
2 files changed, 9 insertions, 7 deletions
diff --git a/tests/swh.scm b/tests/swh.scm
index e36c54e5fb..aef68acbe7 100644
--- a/tests/swh.scm
+++ b/tests/swh.scm
@@ -1,5 +1,5 @@
;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2019 Ludovic Courtès <ludo@gnu.org>
+;;; Copyright © 2019, 2020 Ludovic Courtès <ludo@gnu.org>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -25,8 +25,7 @@
;; Test the JSON mapping machinery used in (guix swh).
(define %origin
- "{ \"id\": 42,
- \"visits_url\": \"/visits/42\",
+ "{ \"visits_url\": \"/visits/42\",
\"type\": \"git\",
\"url\": \"http://example.org/guix.git\" }")
@@ -48,11 +47,10 @@
(test-begin "swh")
(test-equal "lookup-origin"
- (list 42 "git" "http://example.org/guix.git")
+ (list "git" "http://example.org/guix.git")
(with-json-result %origin
(let ((origin (lookup-origin "http://example.org/guix.git")))
- (list (origin-id origin)
- (origin-type origin)
+ (list (origin-type origin)
(origin-url origin)))))
(test-equal "lookup-origin, not found"
diff --git a/tests/ui.scm b/tests/ui.scm
index d8573e88d8..05eace6721 100644
--- a/tests/ui.scm
+++ b/tests/ui.scm
@@ -1,5 +1,5 @@
;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2019 Ludovic Courtès <ludo@gnu.org>
+;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2019, 2020 Ludovic Courtès <ludo@gnu.org>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -227,6 +227,10 @@ Second line" 24))
(expt 2 40)
(size->number "1T"))
+(test-equal "size->number, 1.M"
+ (expt 2 20)
+ (size->number "1.M"))
+
(test-assert "size->number, invalid unit"
(catch 'quit
(lambda ()