From patchwork Sun Jun 16 16:02:32 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonatan Schlag X-Patchwork-Id: 7867 Return-Path: Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) client-signature ECDSA (secp384r1)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4W2Hqf2RKgz3wy2 for ; Sun, 16 Jun 2024 16:03:26 +0000 (UTC) Received: from mail02.haj.ipfire.org (mail02.haj.ipfire.org [172.28.1.201]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) client-signature ECDSA (secp384r1)) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4W2Hqc43rfz5nc; Sun, 16 Jun 2024 16:03:24 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4W2HqX72LMz33Fw; Sun, 16 Jun 2024 16:03:20 +0000 (UTC) Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) client-signature ECDSA (secp384r1)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4W2HqV1d02z2xtd for ; Sun, 16 Jun 2024 16:03:18 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4W2HqL69BJz5n3; Sun, 16 Jun 2024 16:03:10 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1718553790; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=5A+6p0t/W5Mf97oqBDCzkPZlVyEgKT4bvPxZBU+kDtY=; b=pFkPub+XLrwZ/nMBAwLIv12XTt+SqMVx2hP7NsMMn5d0/mtaGOXuBrhq2ZBbBFDLe3e66w T7piI/yL9+fMQ9BQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1718553790; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=5A+6p0t/W5Mf97oqBDCzkPZlVyEgKT4bvPxZBU+kDtY=; b=bFtgY0QbroFpE0p1Gs/rz0Aijsec8H57U8iL5PiIR5X8qrXy+S7mM+rYyPuITG5ecUNXJh +8pBYUezGO6cqVadLqQkCyNmegAIS1+rkEw0XqPO2RyTQCocy7IkrbXLccW8kvorJSKipd mUbNQUbFpi6FPnCV5ut1zxWaigy4qcBhZS3VmqqnTyFQaCjqF6AuN5D1QijSiyi5ZzFxff 3r1aOMPlMo95Cm51KyNfpIN3TZ3AJT3SzsBJwrGs6Mpd/We+Y+L2OfnOtYjJb0OUZuofQc LWG/DlOgJnsEBQoNGPuNLChW2BZhmvx/q66QOIrL33oDUNhdyUDTCzobLvZhRQ== From: Jonatan Schlag To: development@lists.ipfire.org Subject: [PATCH v2 05/18] tests/lib.sh: adjust to pytest logging style Date: Sun, 16 Jun 2024 18:02:32 +0200 Message-Id: <20240616160245.18865-6-jonatan.schlag@ipfire.org> In-Reply-To: <20240616160245.18865-1-jonatan.schlag@ipfire.org> References: <20240616160245.18865-1-jonatan.schlag@ipfire.org> MIME-Version: 1.0 Message-ID-Hash: 2J6PTWAIT7VOHBNQ6ESOLN5F536GNLXN X-Message-ID-Hash: 2J6PTWAIT7VOHBNQ6ESOLN5F536GNLXN X-MailFrom: jonatan.schlag@ipfire.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.8 Precedence: list List-Id: IPFire development talk Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Black on white is still the best to read. So we only style FAILED or PASSED in green or red. This is also tested with different background colors. As we only style PASSED or FAILED it works without any problems Signed-off-by: Jonatan Schlag --- tests/lib.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/lib.sh b/tests/lib.sh index e462f4add..f49a94748 100644 --- a/tests/lib.sh +++ b/tests/lib.sh @@ -12,11 +12,11 @@ LIB_DIR="$(dirname "${LIB_DIR}")" . ${LIB_DIR}/lib_color.sh log_test_failed(){ - echo -e "${CLR_RED_BG}Test failed: ${*}${CLR_RESET}'" + echo -e "${CLR_RED_R}FAILED:${CLR_RESET} ${*}" } log_test_succeded(){ - echo -e "${CLR_GREEN_BG}Test succeded: ${*}${CLR_RESET}" + echo -e "${CLR_GREEN_R}PASSED:${CLR_RESET} ${*}" } test_command() {