projects/guix·commit 8b044314

tests: Fix the git-http test.

8b044314 · Mathieu Othacehe <[email protected]> · 2025-10-21 14:20:58 +02:00

The test fails because the fcgiwrap daemon that runs as "fcgiwrap" user cannot
access the /srv/git directory that is root-owned.

* gnu/tests/version-control.scm (run-git-http-test): Change the ownership
of /srv/git so that fcgiwrap can access it.

Change-Id: I01fa98e3311ac0dba88a4af21cee3ae0da986582
Commit
8b044314334b7d5932548b0f73422d5a943ebcfd
Parents
c7b40a21

Changes

1 files changed · +8 −0

FileStatusAddDelContent
gnu/tests/version-control.scmmodified+8−0View file

gnu/tests/version-control.scm

View file
diff --git a/gnu/tests/version-control.scm b/gnu/tests/version-control.scm
index 8b02d3d..0f35e55 100644
--- a/gnu/tests/version-control.scm
+++ b/gnu/tests/version-control.scm
@@ -286,6 +286,14 @@ HTTP-PORT."
(test-equal "clone"
'#$README-contents
(begin
+ ;; Make sure that the fcgiwrap user can access the /srv/git
+ ;; directory and its child.
+ (marionette-eval
+ '(let ((user (getpw (pk "fcgiwrap"))))
+ (for-each (lambda (dir)
+ (chown dir (passwd:uid user) (passwd:gid user)))
+ '("/srv/git" "/srv/git/test")))
+ marionette)
(invoke #$(file-append git "/bin/git") "clone" "-v"
"http://localhost:8080/git/test" "/tmp/clone")
(call-with-input-file "/tmp/clone/README"