diff options
| author | Ludovic Courtès <ludo@gnu.org> | 2015-04-04 21:59:25 +0200 |
|---|---|---|
| committer | Ludovic Courtès <ludo@gnu.org> | 2018-11-12 23:37:13 +0100 |
| commit | 9ed86fe175c15c819d6d86681c8136ff6bc927c0 (patch) | |
| tree | 15403c26a4048013764c36f40d7e97d5d0066b7d /tests | |
| parent | e740a902281bb3bde369cc04f26656de608d3614 (diff) | |
tests: Add 'test-assertm' to (guix tests).
* guix/tests.scm (test-assertm): New macro.
* tests/gexp.scm (test-assertm): Remove.
* tests/profiles.scm (test-assertm): Remove.
* tests/challenge.scm (%store, test-assertm): Remove.
* tests/debug-link.scm (%store, test-assertm): Remove.
* tests/size.scm (%store, test-assertm): Remove.
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/challenge.scm | 8 | ||||
| -rw-r--r-- | tests/debug-link.scm | 8 | ||||
| -rw-r--r-- | tests/gexp.scm | 5 | ||||
| -rw-r--r-- | tests/profiles.scm | 11 | ||||
| -rw-r--r-- | tests/size.scm | 8 |
5 files changed, 0 insertions, 40 deletions
diff --git a/tests/challenge.scm b/tests/challenge.scm index 4b13ec278e2..c962800f3f9 100644 --- a/tests/challenge.scm +++ b/tests/challenge.scm | |||
| @@ -31,17 +31,9 @@ | |||
| 31 | #:use-module (rnrs bytevectors) | 31 | #:use-module (rnrs bytevectors) |
| 32 | #:use-module (ice-9 match)) | 32 | #:use-module (ice-9 match)) |
| 33 | 33 | ||
| 34 | (define %store | ||
| 35 | (open-connection-for-tests)) | ||
| 36 | |||
| 37 | (define query-path-hash* | 34 | (define query-path-hash* |
| 38 | (store-lift query-path-hash)) | 35 | (store-lift query-path-hash)) |
| 39 | 36 | ||
| 40 | (define-syntax-rule (test-assertm name exp) | ||
| 41 | (test-assert name | ||
| 42 | (run-with-store %store exp | ||
| 43 | #:guile-for-build (%guile-for-build)))) | ||
| 44 | |||
| 45 | (define* (call-with-derivation-narinfo* drv thunk hash) | 37 | (define* (call-with-derivation-narinfo* drv thunk hash) |
| 46 | (lambda (store) | 38 | (lambda (store) |
| 47 | (with-derivation-narinfo drv (sha256 => hash) | 39 | (with-derivation-narinfo drv (sha256 => hash) |
diff --git a/tests/debug-link.scm b/tests/debug-link.scm index 2dde3cb4607..a1ae4f141c0 100644 --- a/tests/debug-link.scm +++ b/tests/debug-link.scm | |||
| @@ -43,14 +43,6 @@ | |||
| 43 | (define read-elf | 43 | (define read-elf |
| 44 | (compose parse-elf get-bytevector-all)) | 44 | (compose parse-elf get-bytevector-all)) |
| 45 | 45 | ||
| 46 | (define %store | ||
| 47 | (open-connection-for-tests)) | ||
| 48 | |||
| 49 | (define-syntax-rule (test-assertm name exp) | ||
| 50 | (test-assert name | ||
| 51 | (run-with-store %store exp | ||
| 52 | #:guile-for-build (%guile-for-build)))) | ||
| 53 | |||
| 54 | 46 | ||
| 55 | (test-begin "debug-link") | 47 | (test-begin "debug-link") |
| 56 | 48 | ||
diff --git a/tests/gexp.scm b/tests/gexp.scm index 467370f8cbc..ab60bdab682 100644 --- a/tests/gexp.scm +++ b/tests/gexp.scm | |||
| @@ -62,11 +62,6 @@ | |||
| 62 | #:target target) | 62 | #:target target) |
| 63 | #:guile-for-build (%guile-for-build))) | 63 | #:guile-for-build (%guile-for-build))) |
| 64 | 64 | ||
| 65 | (define-syntax-rule (test-assertm name exp) | ||
| 66 | (test-assert name | ||
| 67 | (run-with-store %store exp | ||
| 68 | #:guile-for-build (%guile-for-build)))) | ||
| 69 | |||
| 70 | (define %extension-package | 65 | (define %extension-package |
| 71 | ;; Example of a package to use when testing 'with-extensions'. | 66 | ;; Example of a package to use when testing 'with-extensions'. |
| 72 | (dummy-package "extension" | 67 | (dummy-package "extension" |
diff --git a/tests/profiles.scm b/tests/profiles.scm index 9f366a04eff..1f9bbd099da 100644 --- a/tests/profiles.scm +++ b/tests/profiles.scm | |||
| @@ -47,17 +47,6 @@ | |||
| 47 | ;; Globally disable grafts because they can trigger early builds. | 47 | ;; Globally disable grafts because they can trigger early builds. |
| 48 | (%graft? #f) | 48 | (%graft? #f) |
| 49 | 49 | ||
| 50 | (define-syntax-rule (test-assertm name exp) | ||
| 51 | (test-assert name | ||
| 52 | (run-with-store %store exp | ||
| 53 | #:guile-for-build (%guile-for-build)))) | ||
| 54 | |||
| 55 | (define-syntax-rule (test-equalm name value exp) | ||
| 56 | (test-equal name | ||
| 57 | value | ||
| 58 | (run-with-store %store exp | ||
| 59 | #:guile-for-build (%guile-for-build)))) | ||
| 60 | |||
| 61 | ;; Example manifest entries. | 50 | ;; Example manifest entries. |
| 62 | 51 | ||
| 63 | (define guile-1.8.8 | 52 | (define guile-1.8.8 |
diff --git a/tests/size.scm b/tests/size.scm index 575b1abfdd6..0aaa8fbc298 100644 --- a/tests/size.scm +++ b/tests/size.scm | |||
| @@ -30,14 +30,6 @@ | |||
| 30 | #:use-module (srfi srfi-1) | 30 | #:use-module (srfi srfi-1) |
| 31 | #:use-module (srfi srfi-64)) | 31 | #:use-module (srfi srfi-64)) |
| 32 | 32 | ||
| 33 | (define %store | ||
| 34 | (open-connection-for-tests)) | ||
| 35 | |||
| 36 | (define-syntax-rule (test-assertm name exp) | ||
| 37 | (test-assert name | ||
| 38 | (run-with-store %store exp | ||
| 39 | #:guile-for-build (%guile-for-build)))) | ||
| 40 | |||
| 41 | 33 | ||
| 42 | (test-begin "size") | 34 | (test-begin "size") |
| 43 | 35 | ||
