From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id QNo3AxRA0WWUHQEA62LTzQ:P1 (envelope-from ) for ; Sun, 18 Feb 2024 00:24:04 +0100 Received: from aspmx1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1.migadu.com with LMTPS id QNo3AxRA0WWUHQEA62LTzQ (envelope-from ) for ; Sun, 18 Feb 2024 00:24:04 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=twilken.net header.s=mythic-beasts-k1 header.b=pnLFix5Z; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1708212244; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=NTYaZ1EfojnAL+zCAVmY1BgWf5uhsUTC2oX96DK/LtA=; b=ko+2IP2Mpc9zDapfT0f/TyKt92BaxNXBKCXWYTkJt4mg65nbXUbbSN2+tLntkJTxlLlS3c h0S5Du3Fqv65akR1Ir9LOKLoU4eBWI2Q8UxpX4Eh+E7znW8CfH145VIuqfaJPBTXseWRKm EuLjgoeNFBM3CTu3RSx0y0LS+tqtSzcY9oCbcUKdPQbYDZevHu5QujW0Ab1ifnFM3KPOAE gPF+NSERjjSY3xRjtAVb29zsMhGDndUVXocFJMLmgfy/vRmD7TJRHB9db0q/OYSlrPTgs6 JgHUs7Vz+pS5cGg3hQz6TkxekpAkv9a49l5MM373B0UWBb24FY7XafWdChNaHg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=twilken.net header.s=mythic-beasts-k1 header.b=pnLFix5Z; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=none ARC-Seal: i=1; s=key1; d=yhetil.org; t=1708212244; a=rsa-sha256; cv=none; b=IkYlz3jSqpFDlcVHH++W576ivthlVjeg+HnqX6PHL1LsuoUojy5uBxqJOwUjhfWzBdEHxq +qq4UCjsQSGAw1vv6DnnR3d//u0M4VKyN6ZjO7q0ACNpf0i3fgSPXmIjOpqmtBVZEBF0sd axOfftepjjEn3Z/pKBUkfRqsowwD4IqxwLX9hyBjnTVF8StNXZttGJw+dLyo+7nJFF/5lK dn9e5plthuE/Ppq6dZjhqSWs/hBorU82D6LHJ1kP1e5goaJZmVFRXt1+tYPkSp+maRC9f6 LbW4BDD924NYup0iV1viY5akJhW+TKYX/E/smLBJqDTvPLNIibl5zfO0i7ZxkQ== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 49BB273FBA for ; Sun, 18 Feb 2024 00:24:02 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rbU24-0000rK-VT; Sat, 17 Feb 2024 18:23:45 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rbU23-0000r4-Bc for guix-patches@gnu.org; Sat, 17 Feb 2024 18:23:43 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rbU23-0001Is-3u for guix-patches@gnu.org; Sat, 17 Feb 2024 18:23:43 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rbU2N-0007JH-6T for guix-patches@gnu.org; Sat, 17 Feb 2024 18:24:03 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#63877] [PATCH 2/2] tests: web: Test environment variables are set for php-fpm. Resent-From: guix@twilken.net Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 17 Feb 2024 23:24:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 63877 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: moreinfo patch To: 63877@debbugs.gnu.org Cc: Ludovic =?UTF-8?Q?Court=C3=A8s?= , Bruno Victal , Timo Wilken Received: via spool by 63877-submit@debbugs.gnu.org id=B63877.170821222828065 (code B ref 63877); Sat, 17 Feb 2024 23:24:03 +0000 Received: (at 63877) by debbugs.gnu.org; 17 Feb 2024 23:23:48 +0000 Received: from localhost ([127.0.0.1]:33999 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rbU28-0007Ib-GR for submit@debbugs.gnu.org; Sat, 17 Feb 2024 18:23:48 -0500 Received: from mx2.mythic-beasts.com ([46.235.227.24]:33979) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rbU27-0007IE-HK for 63877@debbugs.gnu.org; Sat, 17 Feb 2024 18:23:47 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=twilken.net ; s=mythic-beasts-k1; h=Date:Subject:To:From; bh=NTYaZ1EfojnAL+zCAVmY1BgWf5uhsUTC2oX96DK/LtA=; b=pnLFix5ZFRQyalXO0f+SWjO423 vQk6dpXdEk690T0h8PLtEUmZ17rZuqoBOGJKbR3D+ytrUGIDLUt6dEozzpcujdL0Ej8+BuFf9Siwa 1I5O4yqeCwhznGtVG+geTrzK4FQePjXRs4jx1H9oH3SpCq6xu1SXk93mUROQogWJQpLyzmHxzcOcR lVC9cNtZvycEyv2A+gJfud+iv214G/JUBwt7WzF8selb+2DQBlaJ+mM6EePpu67b9JKWOxKvlGbHy 9oP/BvtzuxqoHryolq+X5az2du8fKfnb/RWNVAtRckIk3r4F+l7luCi+GXTYAsdGizlgJw+Hf0l03 MFLKvtCA==; Received: by mailhub-hex-d.mythic-beasts.com with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rbU1h-00BbpP-C6; Sat, 17 Feb 2024 23:23:21 +0000 From: guix@twilken.net Date: Sun, 18 Feb 2024 00:21:47 +0100 Message-ID: <20240217232151.12507-4-guix@twilken.net> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20240217232151.12507-1-guix@twilken.net> References: <7be3201e-af9b-4ad0-81d6-44ab316d2162@makinata.eu> <20240217232151.12507-1-guix@twilken.net> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BlackCat-Spam-Score: 49 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Scanner: mx10.migadu.com X-Migadu-Spam-Score: -2.11 X-Spam-Score: -2.11 X-Migadu-Queue-Id: 49BB273FBA X-TUID: Y7njcd3yFClm From: Timo Wilken Test the new `environment-variables' field of by looking for a sentinel variable and value in the output of `phpinfo()'. * gnu/tests/web.scm (run-php-fpm-test): Add test case. --- gnu/tests/web.scm | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/gnu/tests/web.scm b/gnu/tests/web.scm index 16dc6bea49..f1688bfd3a 100644 --- a/gnu/tests/web.scm +++ b/gnu/tests/web.scm @@ -272,7 +272,10 @@ (define %php-fpm-os ;; Operating system under test. (simple-operating-system (service dhcp-client-service-type) - (service php-fpm-service-type) + (service php-fpm-service-type + (php-fpm-configuration + (environment-variables + '(("GUIX_TEST_PHPFPM_ENV" . "sentinel"))))) (service nginx-service-type (nginx-configuration (server-blocks %php-fpm-nginx-server-blocks))) @@ -345,6 +348,13 @@ (define marionette (and matches (match:substring matches 0)))))) + (test-assert "php environment variable is applied" + (let-values (((response text) + (http-get "http://localhost:8080/index.php" + #:decode-body? #t))) + (and (string-contains text "GUIX_TEST_PHPFPM_ENV") + (string-contains text "sentinel")))) + (test-end)))) (gexp->derivation "php-fpm-test" test)) -- 2.41.0