From: "Ludovic Courtès" <ludo@gnu.org>
To: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Cc: Mathieu Othacehe <othacehe@gnu.org>, 54786@debbugs.gnu.org
Subject: bug#54786: Installation tests are failing
Date: Sat, 28 May 2022 23:29:54 +0200 [thread overview]
Message-ID: <878rql9wh9.fsf@gnu.org> (raw)
In-Reply-To: <87a6b646qs.fsf@gmail.com> (Maxim Cournoyer's message of "Tue, 24 May 2022 23:43:23 -0400")
[-- Attachment #1: Type: text/plain, Size: 1450 bytes --]
Hi Maxim,
Maxim Cournoyer <maxim.cournoyer@gmail.com> skribis:
> Ludovic Courtès <ludo@gnu.org> writes:
>
>> Hi,
>>
>> Mathieu Othacehe <othacehe@gnu.org> skribis:
>>
>>> Thanks for the fix! The jami and jami-provisioning tests are also broken
>>> because of what looks like to be the same issue:
>>>
>>> One does not simply initialize the client: Another daemon is detected
>>> /gnu/store/01phrvxnxrg1q0gxa35g7f77q06crf6v-shepherd-marionette.scm:1:1718: ERROR:
>>> 1. &action-exception-error:
>>> service: jami
>>> action: start
>>> key: match-error
>>> args: ("match" "no matching pattern" #f)
>>> Jami Daemon 11.0.0, by Savoir-faire Linux 2004-2019
>>> https://jami.net/
>>> [Video support enabled]
>>> [Plugins support enabled]
>>
>> Yes, I noticed that, but I’m not sure how to apply a similar workaround.
>
> I tried fixing that today, but so far I've only managed to understand
> what seems to be going wrong, with this (not so great) workflow:
While working on <https://issues.guix.gnu.org/55444>, I figured
‘wait-for-service’ could be useful for system tests that were previously
using ‘start-service’ as a way to wait for a service to be up and
running.
I tried the following change, which should be semantically equivalent to
what was happening with the Shepherd 0.8. However, it doesn’t seem to
work, for reasons that escape me.
Thoughts?
Ludo’.
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: Type: text/x-patch, Size: 2012 bytes --]
diff --git a/gnu/tests/telephony.scm b/gnu/tests/telephony.scm
index bc464a431a..c219868859 100644
--- a/gnu/tests/telephony.scm
+++ b/gnu/tests/telephony.scm
@@ -145,11 +145,7 @@ (define marionette
(marionette-eval
'(begin
(use-modules (gnu services herd))
- (match (start-service 'jami)
- (#f #f)
- (('service response-parts ...)
- (match (assq-ref response-parts 'running)
- ((pid) (number? pid))))))
+ (wait-for-service 'jami #:timeout 60))
marionette))
(test-assert "service can be stopped"
@@ -158,12 +154,7 @@ (define marionette
(use-modules (gnu services herd)
(rnrs base))
(setenv "PATH" "/run/current-system/profile/bin")
- (let ((pid (match (start-service 'jami)
- (#f #f)
- (('service response-parts ...)
- (match (assq-ref response-parts 'running)
- ((pid) pid))))))
-
+ (let ((pid (wait-for-service 'jami)))
(assert (number? pid))
(match (stop-service 'jami)
@@ -193,14 +184,10 @@ (define pid (match (start-service 'jami)
;; Restart the service.
(restart-service 'jami)
- (define new-pid (match (start-service 'jami)
- (#f #f)
- (('service response-parts ...)
- (match (assq-ref response-parts 'running)
- ((pid) pid)))))
+ (define new-pid (wait-for-service 'jami))
(assert (number? new-pid))
- (not (eq? pid new-pid)))
+ (not (= pid new-pid)))
marionette))
(unless #$provisioning? (test-skip 1))
next prev parent reply other threads:[~2022-05-28 21:31 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-08 9:51 bug#54786: Installation tests are failing Mathieu Othacehe
2022-04-08 15:10 ` Mathieu Othacehe
2022-04-28 7:22 ` Mathieu Othacehe
2022-04-28 19:19 ` Ludovic Courtès
2022-04-29 19:50 ` Ludovic Courtès
2022-04-30 13:02 ` Mathieu Othacehe
2022-05-01 13:26 ` Ludovic Courtès
2022-05-25 3:43 ` Maxim Cournoyer
2022-05-28 21:29 ` Ludovic Courtès [this message]
2022-05-31 16:44 ` bug#54786: [PATCH] services: jami: Modernize to adjust to Shepherd 0.9+ changes Maxim Cournoyer
2022-06-01 9:54 ` bug#54786: Installation tests are failing Ludovic Courtès
2022-06-01 13:10 ` Maxim Cournoyer
2022-06-02 13:13 ` Ludovic Courtès
2022-06-02 17:24 ` Maxim Cournoyer
2022-06-02 20:43 ` Ludovic Courtès
2022-06-04 4:37 ` Maxim Cournoyer
2022-06-07 14:00 ` Ludovic Courtès
2022-06-08 0:58 ` bokr
2022-06-11 4:18 ` Maxim Cournoyer
2022-08-09 14:20 ` Mathieu Othacehe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=878rql9wh9.fsf@gnu.org \
--to=ludo@gnu.org \
--cc=54786@debbugs.gnu.org \
--cc=maxim.cournoyer@gmail.com \
--cc=othacehe@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).