summary refs log tree commit diff
path: root/tests
AgeCommit message (Collapse)Author
2018-03-31guix package: Add '--allow-collisions'.Ludovic Courtès
Fixes <https://bugs.gnu.org/30830>. Suggested by Ricardo Wurmus <rekado@elephly.net>. * guix/scripts/package.scm (build-and-use-profile): Add #:allow-collisions? and pass it to 'profile-derivation'. (show-help, %options): Add '--allow-collisions'. (manifest-action, process-actions): Pass #:allow-collisions? to 'build-and-use-profile'. * tests/guix-package.sh: Add collision test. * doc/guix.texi (Invoking guix package): Document '--allow-collisions'.
2018-03-27guix gc: Add '--derivers'.Ludovic Courtès
* guix/scripts/gc.scm (show-help, %options): Add '--derivers'. (guix-gc): Handle 'list-derivers'. * tests/guix-gc.sh: Add test. * doc/guix.texi (Invoking guix gc): Document it.
2018-03-27graph: Add "module" node type.Ludovic Courtès
* guix/scripts/graph.scm (module-from-package) (source-module-dependencies*): New procedures. (%module-node-type): New variable. (%node-types): Add it. * guix/modules.scm (source-module-dependencies): Export. * tests/graph.scm ("module graph"): New test. * doc/guix.texi (Invoking guix graph): Document it.
2018-03-24tests: Add tests for "guix system disk-image" et al.Chris Marusich
* tests/guix-system.sh: Add test cases that exercise (1) all of the example files in gnu/system/examples, and (2) all of the "image" creation commands: vm, vm-image, disk-image, and docker-image.
2018-03-24tests: Add tests for "guix pack".Chris Marusich
* guix/scripts/pack.scm (bootstrap-xz): New variable. (%options) <--bootstrap>: New option. (show-help): Document the new --bootstrap option. (guix-pack): When --bootstrap is specified, use the bootstrap Guile, tar, and xz to build the pack, and do not use any profile hooks or locales. * doc/guix.texi (Invoking guix pull): Document the new --bootstrap option. * tests/guix-pack.sh: New file. * Makefile.am (SH_TESTS): Add guix-pack.sh. * gnu/packages/package-management.scm (guix) <inputs>: Add util-linux.
2018-03-23gexp: 'program-file' has a new #:module-path parameter.Ludovic Courtès
* guix/gexp.scm (<program-file>): Add 'path' field. (program-file): Add #:module-path parameter and honor it. (program-file-compiler): Honor the 'path' field. * tests/gexp.scm ("program-file #:module-path"): New test. * doc/guix.texi (G-Expressions): Update.
2018-03-23gexp: 'gexp->script' and 'gexp->file' have a new #:module-path parameter.Ludovic Courtès
* guix/gexp.scm (load-path-expression): Add 'path' optional parameter. (gexp->script): Add #:module-path and honor it. (gexp->file): Likewise. * tests/gexp.scm ("gexp->script #:module-path"): New test. * doc/guix.texi (G-Expressions): Update accordingly.
2018-03-22publish: Always build a new derivation for the "/log/NAME" test.Ludovic Courtès
Fixes <https://bugs.gnu.org/30868>. Reported by Martin Castillo <castilma@uni-bremen.de>. * tests/publish.scm ("/log/NAME"): Use #$(random-text) in the builder.
2018-03-22publish: Add test for non-GET queries.Ludovic Courtès
* tests/publish.scm ("non-GET query"): New test.
2018-03-18glob: Add an extra glob pattern compilation stage.Ludovic Courtès
* guix/glob.scm (compile-glob-pattern): Rename to... (string->sglob): ... this. (compile-sglob, string->compiled-sglob): New procedures. (glob-match?): Replace '?, 'range, and 'set with a single clause. * tests/glob.scm (test-compile-glob-pattern): Rename to... (test-string->sglob): ... this. Adjust accordingly. (test-glob-match): Use 'string->compiled-sglob' instead of 'compile-glob-pattern'. * gnu/build/linux-modules.scm (read-module-aliases): Use 'string->compiled-sglob' instead of 'compile-glob-pattern'.
2018-03-18glob: Support square brackets in patterns.Ludovic Courtès
* guix/glob.scm (wildcard-indices): Remove. (parse-bracket): New procedure. (compile-glob-pattern): Rewrite. Support square brackets for sets and ranges. (glob-match?): Support sets and ranges. * tests/glob.scm (test-compile-glob-pattern) (test-glob-match): New macros. Use them to rewrite the existing tests, and add new tests.
2018-03-18tests: elpa: Don't actually download files.Ludovic Courtès
* tests/elpa.scm (eval-test-with-elpa): Mock 'url-fetch'.
2018-03-18import: elpa: Adjust test for HTTPS URLs.Ludovic Courtès
This is a followup to 44dd3d579db3aa467e41d0b431029e46cae8e12d. * tests/elpa.scm (eval-test-with-elpa): Use https.
2018-03-15tests: Do not assume the bootstrap guile tarball is available locally.Ludovic Courtès
Fixes <https://bugs.gnu.org/30824>. Reported by Chris Marusich <cmmarusich@gmail.com>. * tests/packages.scm ("package-source-derivation, snippet"): Use 'bootstrap-guile-origin' instead of assuming the bootstrap guile tarball is available locally.
2018-03-13gnu: time: Update to 1.9.Efraim Flashner
* gnu/packages/time.scm (time): Update to 1.9. * tests/guix-build.sh: Update time package to 1.9.
2018-03-08hash: Add 'sha1'.Ludovic Courtès
* guix/hash.scm (GCRY_MD_SHA1): New macro. (bytevector-hash): New procedure. (sha256): Express in terms of 'bytevector-hash'. (sha1): New procedure. * tests/hash.scm ("sha1, empty", "sha1, hello"): New tests.
2018-03-02Add (guix glob).Ludovic Courtès
* guix/glob.scm, tests/glob.scm: New files. * Makefile.am (MODULES): Add guix/glob.scm. (SCM_TESTS): Add tests/glob.scm.
2018-03-02environment: Add --user.Mike Gerwitz
This change allows overriding the home directory of all filesystem mappings to help hide the identity of the calling user in a container. * doc/guix.texi (Invoking guix environment)[--container]: Mention --user. [--user]: Add item. * guix/scripts/environment.scm (show-help): Add --user. (%options): Add --user. (launch-environment/container) Add 'user' parameter. Update doc. Override 'user-mappings' using 'override-user-mappings'. Consider override for chdir. (mock-passwd, user-override-home, overrid-euser-dir): New procedures. (guix-environment): Disallow --user without --container. Provide user to 'launch-environment/container'. * tests/guix-environment.sh: Add user test. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2018-03-02environment: Add --link-profile.Mike Gerwitz
This change is motivated by attempts to run programs (like GNU IceCat) within containers. The 'fontconfig' program, for example, is configured explicitly to check ~/.guix-profile for additional fonts. There were no existing container tests in 'tests/guix-environment.sh', but I added one anyway for this change. * doc/guix.texi (Invoking guix environment): Add '--link-profile'. * guix/scripts/environment.scm (show-help): Add '--link-profile'. (%options): Add 'link-profile' as '#\P', assigned to 'link-profile?'. (link-environment): New procedure. (launch-environment/container): Use it when 'link-profile?'. [link-profile?]: New parameter. (guix-environment): Leave when '--link-prof' but not '--container'. Add '#:link-profile?' argument to 'launch-environment/container' application. * tests/guix-environment-container.sh: New '--link-profile' test. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2018-03-01profiles: 'manifest-add' truly deletes duplicate entries.Ludovic Courtès
Fixes <https://bugs.gnu.org/30569>. Reported by Andreas Enge <andreas@enge.fr>. * guix/profiles.scm (manifest-add): Don't append ENTRIES as is. Instead, cons each element of ENTRIES as we fold over it. Remove unneeded ellispes in 'match' patterns.
2018-02-28build-system/trivial: Add support for #:allowed-references.Ludovic Courtès
* guix/build-system/trivial.scm (lower): Add #:allowed-references and keep it in the 'arguments' field. (trivial-build): Add #:allowed-references. Add 'canonicalize-reference'. Pass #:allowed-references to 'build-expression->derivation'. (trivial-cross-build): Likewise. * tests/packages.scm ("trivial with #:allowed-references"): New test.
2018-02-27guix package: '--search' no longer shows superseded packages.Ludovic Courtès
Fixes <https://bugs.gnu.org/30566>. Reported by Björn Höfling <bjoern.hoefling@bjoernhoefling.de>. * guix/scripts/package.scm (find-packages-by-description): Ignore superseded packages. * tests/guix-package.sh: Add test.
2018-02-26build: Require Guile >= 2.0.13.Ludovic Courtès
* README, configure.ac, doc/guix.texi (Requirements): Increase minimum Guile version from 2.0.9 to 2.0.13. * config-daemon.ac: Remove use of 'GUIX_CHECK_UNBUFFERED_CBIP'. * m4/guix.m4 (GUIX_CHECK_UNBUFFERED_CBIP): Remove. * guix/build/download.scm (current-http-proxy): Remove. * guix/build/syscalls.scm (%libc-errno-pointer, errno): Remove. (syscall->procedure): Use #:return-errno unconditionally. * guix/hash.scm (open-sha256-input-port)[unbuffered]: Remove outdated comment. * guix/http-client.scm (when-guile<=2.0.5-or-otherwise-broken): Remove. <top level>: Remove 'when-guile<=2.0.5-or-otherwise-broken' block. * guix/scripts/substitute.scm (fetch): Remove 'guile-version>?' conditional. * tests/hash.scm (supports-unbuffered-cbip?): Remove. <top level>: Remove 'test-skip' call.
2018-02-21environment: Add --manifest option.David Thompson
* guix/scripts/environment.scm (show-help, %options): Add -m/--manifest. (options/resolve-packages): Handle manifests. * tests/guix-envronment.sh: Add a test. * doc/guix.texi (Invoking guix environment): Document it.
2018-02-16Merge branch 'master' into core-updatesMark H Weaver
2018-02-16import: utils: 'alist->package' allows false license.Ludovic Courtès
Reported by <pkill9@runbox.com>. Fixes <https://bugs.gnu.org/30470>. * guix/import/utils.scm (alist->package): Check whether 'license' is false and set the 'license' field to #f in this case. * tests/import-utils.scm ("alist->package with false license"): New test.
2018-02-01Merge branch 'master' into core-updatesMarius Bakke
2018-01-30derivations: Adjust tests for Stow environments.Ludovic Courtès
Fixes <https://bugs.gnu.org/30250>. Reported by Jorge <jorge+list@disroot.org>. * tests/derivations.scm ("add-to-store, flat") ("add-to-store, recursive"): Call 'readlink*'.
2018-01-23Merge branch 'master' into core-updatesMark H Weaver
2018-01-22publish: Restore gzip compression in cache-less mode.Ludovic Courtès
Fixes <https://bugs.gnu.org/30184>. Regression introduced in 297e04d66010ada31a40f40143d81bf6b62affcc. Reported by Christopher Baines <mail@cbaines.net>. * guix/scripts/publish.scm (nar-response-port): Add 'compression' parameter and honor it. (http-write): Get 'x-nar-compression' from the initial RESPONSE.
2018-01-21services: Missing services are automatically instantiated.Ludovic Courtès
This simplifies OS configuration: users no longer need to be aware of what a given service depends on. See the discussion at <https://lists.gnu.org/archive/html/guix-devel/2018-01/msg00114.html>. * gnu/services.scm (missing-target-error): New procedure. (service-back-edges): Use it. (instantiate-missing-services): New procedure. * gnu/system.scm (operating-system-services): Call 'instantiate-missing-services'. * tests/services.scm ("instantiate-missing-services") ("instantiate-missing-services, no default value"): New tests. * gnu/services/version-control.scm (cgit-service-type)[extensions]: Add FCGIWRAP-SERVICE-TYPE. * gnu/tests/version-control.scm (%cgit-os): Remove NGINX-SERVICE-TYPE and FCGIWRAP-SERVICE-TYPE instances. * doc/guix.texi (Log Rotation): Remove 'mcron-service-type' in example. (Miscellaneous Services): Remove 'nginx-service-type' and 'fcgiwrap-service-type' in Cgit example.
2018-01-11Merge branch 'master' into core-updatesLeo Famulari
2018-01-07publish: Publish build logs.Ludovic Courtès
* guix/scripts/publish.scm (render-log-file): New procedure. (make-request-handler): Add "log" case. * tests/publish.scm ("/log/NAME") ("/log/NAME not found"): New tests. * doc/guix.texi (Invoking guix publish): Document /log URLs.
2018-01-07daemon: Add gzip log compression.Ludovic Courtès
* nix/nix-daemon/guix-daemon.cc (GUIX_OPT_LOG_COMPRESSION): New macro. (options): Mark "disable-log-compression" as hidden and add "log-compression". (parse_opt): Handle GUIX_OPT_LOG_COMPRESSION. * nix/libstore/build.cc (DerivationGoal): Add 'gzLogFile'. (openLogFile): Initialize it when 'logCompression' is COMPRESSION_GZIP. (closeLogFile, handleChildOutput): Honor 'gzLogFile'. * nix/libstore/globals.hh (Settings)[compressLog]: Remove. [logCompression]: New field. (CompressionType): New enum. * nix/libstore/globals.cc (Settings::Settings): Initialize it. (update): Remove '_get' call for 'compressLog'. * nix/local.mk (guix_daemon_LDADD, guix_register_LDADD): Add -lz. * guix/store.scm (log-file): Handle '.gz' log files. * tests/guix-daemon.sh: Add test with '--log-compression=gzip'. * doc/guix.texi (Invoking guix-daemon): Adjust accordingly. * config-daemon.ac: Check for libz and zlib.h.
2017-12-31Merge remote-tracking branch 'origin/master' into core-updatesEfraim Flashner
2017-12-23guix build: Support '--with-source=PACKAGE@VERSION=URI'.Ludovic Courtès
* guix/scripts/build.scm (numeric-extension?, tarball-base-name): New procedures, formerly in 'package-with-source'. (transform-package-source)[new-sources]: Look for '=' in URI. Each element of the list of now a (PKG VERSION SOURCE) tuple. Pass VERSION to 'package-with-source'. (package-with-source): Add 'version' parameter and honor it. * tests/scripts-build.scm ("options->transformation, with-source, PKG=URI") ("options->transformation, with-source, PKG@VER=URI"): New tests. * doc/guix.texi (Package Transformation Options): Document the new forms.
2017-12-19Merge branch 'master' into core-updatesMarius Bakke
2017-12-18guix gc: '--verify=foo' is reported as an error.Ludovic Courtès
Fixes <https://bugs.gnu.org/29761>. Reported by Martin Castillo <castilma@uni-bremen.de>. * guix/scripts/gc.scm (argument->verify-options): New procedure. (%options) ["verify"]: Adjust to use it. * tests/guix-gc.sh: Add test.
2017-12-17graph: Adjust test for glibc:static among the implicit inputs.Ludovic Courtès
Fixes <https://bugs.gnu.org/29612>. Reported by Chris Marusich <cmmarusich@gmail.com>. This is a followup to 6dff905e51202bbdebbad8811b6509584d12a796. * tests/graph.scm ("bag-emerged DAG"): Adjust for glibc:static among IMPLICIT.
2017-12-10lint: 'check-vulnerabilities' also checks package properties.Efraim Flashner
* guix/scripts/lint.scm (check-vulnerabilities): Also check for CVEs listed as mitigated in the package properties. * tests/lint.scm ("cve: known safe from vulnerability"): New test.
2017-12-06gnu, doc, tests: Use ‘bootloader-configuration’ everywhere.Tobias Geerinckx-Rice
* doc/guix.texi (Proceeding with the Installation): Replace the old-style ‘grub-configuration’ with the newer ‘bootloader-configuration’ syntax. * gnu/system/examples/vm-image.tmpl: Likewise. * gnu/system/install.scm (installation-os): Likewise. * gnu/tests.scm (%simple-os): Likewise. * gnu/tests/install.scm (%minimal-os, %minimal-os-on-vda, %separate-home-os) (%separate-store-os, %raid-root-os, %encrypted-root-os, %btrfs-root-os): Likewise. * gnu/tests/nfs.scm (%base-os): Likewise. * tests/guix-system.scm (OS_BASE, make_user_config): Likewise. * tests/system.scm (%os, %os-with-mapped-device): Likewise.
2017-12-04tests: Look for multi-digit column numbers in unbound variable test.Eric Bavier
* tests/guix-system.sh: Match one or more digits in unbound-variable test.
2017-12-01tests: Avoid double slash in URIs.Ludovic Courtès
* tests/publish.scm ("with cache"): Remove extra slash in NAR-URL. This would lead to a 'uri-error' exception on Guile 2.2.3.
2017-11-28lint: 'patch-file-names' checks for file name length.Ludovic Courtès
Reported at <https://bugs.gnu.org/27943> by Danny Milosavljevic <dannym@scratchpost.org>. * guix/scripts/lint.scm (%distro-directory): New variable. (check-patch-file-names): Add check for the file name length. * tests/lint.scm ("patches: file name too long"): New test.
2017-11-25syscalls: Adjust utmpx test.Ludovic Courtès
Fixes <https://bugs.gnu.org/29426>. Reported by Adonay Felipe Nogueira <adfeno@hyperbola.info>. * tests/syscalls.scm ("utmpx-entries"): Check the value of (utmpx-entries entry) only for INIT_PROCESS, LOGIN_PROCESS, and USER_PROCESS entries.
2017-11-21tests: Disable test for freed disk space that fails on Btrfs.Marius Bakke
This is a follow-up to commit 40e89f5be609045bc2666cc16a4ef80bb7f84095. * tests/store.scm ("dead path can be explicitly collected"): Don't check that (> freed 0). * gnu/packages/package-management.scm (guix)[arguments]<#:phases>: Remove workaround for the same problem.
2017-11-17workers: Add test with exceptions.Ludovic Courtès
* tests/workers.scm ("exceptions"): New test.
2017-11-13tests: 'guix-gc.sh' passes even when 'out' or 'drv' are defined as env vars.Ludovic Courtès
This fixes a test failure exhibited by fb17a89912c2a3738dae716e30481c11e1c6f0ac whereby assignments to 'out' in guix-gc.sh would go to the 'out' environment variable, when it exists, which in turn prevents garbage collection of $out. * tests/guix-gc.sh: Add 'unset' invocations.
2017-11-11tests: Adjust to new unbound-variable error message.Ludovic Courtès
This is a followup to dc856223f5eab57d8a4881782ec0f50abd12afa3. * tests/guix-package.sh: Adjust unbound-variable message regexp.
2017-11-11tests: Refer to "time@1.8".Ludovic Courtès
This is a followup to dd00e0919fcecd895ff4e5a646cf068f46ff8d12. * tests/guix-build.sh: Refer to "time@1.8".