From patchwork Mon Feb 7 22:38:14 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Marius Bakke X-Patchwork-Id: 37073 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id C3A3027BBEA; Mon, 7 Feb 2022 22:42:02 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 85BD027BBE9 for ; Mon, 7 Feb 2022 22:42:02 +0000 (GMT) Received: from localhost ([::1]:36366 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nHCht-0005hd-FS for patchwork@mira.cbaines.net; Mon, 07 Feb 2022 17:42:01 -0500 Received: from eggs.gnu.org ([209.51.188.92]:32830) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nHCfB-0002nx-Pq for guix-patches@gnu.org; Mon, 07 Feb 2022 17:39:14 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:50153) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nHCf0-0005KE-GH for guix-patches@gnu.org; Mon, 07 Feb 2022 17:39:13 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nHCf0-00060G-Ew for guix-patches@gnu.org; Mon, 07 Feb 2022 17:39:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#53862] [PATCH] tests: Add system tests for each supported kernel version. Resent-From: Marius Bakke Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 07 Feb 2022 22:39:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 53862 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 53862@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.164427350223028 (code B ref -1); Mon, 07 Feb 2022 22:39:02 +0000 Received: (at submit) by debbugs.gnu.org; 7 Feb 2022 22:38:22 +0000 Received: from localhost ([127.0.0.1]:44050 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nHCeM-0005zM-5j for submit@debbugs.gnu.org; Mon, 07 Feb 2022 17:38:22 -0500 Received: from lists.gnu.org ([209.51.188.17]:34338) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nHCeJ-0005zD-8R for submit@debbugs.gnu.org; Mon, 07 Feb 2022 17:38:21 -0500 Received: from eggs.gnu.org ([209.51.188.92]:60928) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nHCeI-0002D4-51 for guix-patches@gnu.org; Mon, 07 Feb 2022 17:38:19 -0500 Received: from [2001:470:142:3::e] (port=39354 helo=fencepost.gnu.org) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nHCeG-0005HL-Ru; Mon, 07 Feb 2022 17:38:16 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:Date:Subject:To:From:in-reply-to: references; bh=/F8KaOCpTDeCnm4JOWZH/5OU5Cci064KRfw8b9v153o=; b=hEKiZpleeAxmCT JPXll7bQ0sB6hsVR0xIvmhFF/hPF7rNA31i/hz0MLlkaaeaqCBzNr0iYu4+SomkfRAP9mP0/vxUTu l/hwR0OiSYkgevDz01Ox4FvHmHNEWiX9E7+EAuxoWbgxRx+9+PD+9HAgx7N6yeQhD0i/eDaiSjlmE MwhPtAMMklfh/WfCTSHEO3oiHpqkWd7BDOoeHCU+5SzCUguISPWP7Z9FV6nzm15FyV10jAXu6Kv8m vs0jv2+h8tkqRduNhKmLrMCuqxdZnvdPdUvpC021R0yVXP+AW65nYab54H6JDDM3m6QmZraqf7j+6 6mIeLTlN5Iqwp31xa/Ow==; Received: from host-37-191-236-102.lynet.no ([37.191.236.102]:52104 helo=localhost) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nHCeG-00014Z-GD; Mon, 07 Feb 2022 17:38:16 -0500 From: Marius Bakke Date: Mon, 7 Feb 2022 23:38:14 +0100 Message-Id: <20220207223814.5982-1-marius@gnu.org> X-Mailer: git-send-email 2.34.0 MIME-Version: 1.0 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+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches * gnu/tests/base.scm (test-basic-os-with-kernel): New procedure. (%test-linux-libre-5.10, %test-linux-libre-5.4, %test-linux-libre-4.19, %test-linux-libre-4.14, %test-linux-libre-4.9, %test-linux-libre-4.4): New tests. --- gnu/tests/base.scm | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) --- Guix, I just discovered #52667 and figured it would be neat to have system tests for each kernel to catch regressions faster. WDYT? diff --git a/gnu/tests/base.scm b/gnu/tests/base.scm index 38d4317e52..88de421ed1 100644 --- a/gnu/tests/base.scm +++ b/gnu/tests/base.scm @@ -1,6 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Ludovic Courtès ;;; Copyright © 2018 Clément Lassieur +;;; Copyright © 2022 Marius Bakke ;;; ;;; This file is part of GNU Guix. ;;; @@ -41,10 +42,18 @@ (define-module (gnu tests base) #:use-module (guix store) #:use-module (guix monads) #:use-module (guix packages) + #:use-module (guix utils) #:use-module (srfi srfi-1) #:use-module (ice-9 match) #:export (run-basic-test %test-basic-os + test-basic-os-with-kernel + %test-linux-libre-5.10 + %test-linux-libre-5.4 + %test-linux-libre-4.19 + %test-linux-libre-4.14 + %test-linux-libre-4.9 + %test-linux-libre-4.4 %test-halt %test-cleanup %test-mcron @@ -537,6 +546,38 @@ (define %test-basic-os (run-basic-test (virtualized-operating-system os '()) #~(list #$vm)))))) +(define (test-basic-os-with-kernel kernel) + (system-test + (name (string-append (package-name kernel) "-" + (version-major+minor (package-version kernel)))) + (description "Run %TEST-BASIC-OS with the given KERNEL.") + (value + (let* ((os (marionette-operating-system + (operating-system + (inherit %simple-os) + (kernel kernel)))) + (vm (virtual-machine os))) + (run-basic-test (virtualized-operating-system os '()) + #~(list #$vm)))))) + +(define %test-linux-libre-5.10 + (test-basic-os-with-kernel linux-libre-5.10)) + +(define %test-linux-libre-5.4 + (test-basic-os-with-kernel linux-libre-5.4)) + +(define %test-linux-libre-4.19 + (test-basic-os-with-kernel linux-libre-4.19)) + +(define %test-linux-libre-4.14 + (test-basic-os-with-kernel linux-libre-4.14)) + +(define %test-linux-libre-4.9 + (test-basic-os-with-kernel linux-libre-4.9)) + +(define %test-linux-libre-4.4 + (test-basic-os-with-kernel linux-libre-4.4)) + ;;; ;;; Halt.