From patchwork Fri Feb 21 23:16:52 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 20350 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 1C1D327BBEA; Fri, 21 Feb 2020 23:18:11 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTP id 98DFB27BBE4 for ; Fri, 21 Feb 2020 23:18:10 +0000 (GMT) Received: from localhost ([::1]:37136 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j5HYg-0003fO-6h for patchwork@mira.cbaines.net; Fri, 21 Feb 2020 18:18:10 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:47783) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j5HYb-0003fG-4n for guix-patches@gnu.org; Fri, 21 Feb 2020 18:18:06 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j5HYY-00079j-UW for guix-patches@gnu.org; Fri, 21 Feb 2020 18:18:05 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:42408) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1j5HYY-00079d-Rg for guix-patches@gnu.org; Fri, 21 Feb 2020 18:18:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1j5HYY-0000Pq-Mf; Fri, 21 Feb 2020 18:18:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#39729] [PATCH 0/7] Testing the graphical installer Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: m.othacehe@gmail.com, guix-patches@gnu.org Resent-Date: Fri, 21 Feb 2020 23:18:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 39729 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 39729@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe X-Debbugs-Original-To: guix-patches@gnu.org X-Debbugs-Original-Xcc: Mathieu Othacehe Received: via spool by submit@debbugs.gnu.org id=B.15823270301530 (code B ref -1); Fri, 21 Feb 2020 23:18:02 +0000 Received: (at submit) by debbugs.gnu.org; 21 Feb 2020 23:17:10 +0000 Received: from localhost ([127.0.0.1]:48381 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j5HXi-0000Oc-2t for submit@debbugs.gnu.org; Fri, 21 Feb 2020 18:17:10 -0500 Received: from lists.gnu.org ([209.51.188.17]:38813) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j5HXf-0000OT-JH for submit@debbugs.gnu.org; Fri, 21 Feb 2020 18:17:09 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:47629) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j5HXd-0003ZW-5Q for guix-patches@gnu.org; Fri, 21 Feb 2020 18:17:07 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:44440) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1j5HXd-0006fx-1A; Fri, 21 Feb 2020 18:17:05 -0500 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=40966 helo=gnu.org) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1j5HXc-0000dz-3u; Fri, 21 Feb 2020 18:17:04 -0500 From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Sat, 22 Feb 2020 00:16:52 +0100 Message-Id: <20200221231652.27632-1-ludo@gnu.org> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 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 Hello! Here’s a test for the graphical installer, as discussed earlier at: https://lists.gnu.org/archive/html/guix-devel/2020-01/msg00407.html The first part of this patch series implements client support in the installer as discussed above (only more robust to multiple clients, disconnections, etc.). A dirty bit there is the ‘close-port-and-reuse-fd’ hack, which works around the fact that Newt does not provide a ‘form-unwatch-fd’ procedure. Good enough for now! There are also two hacks to (1) skip connectivity checks and (2) to pass ‘--no-grafts’ to ‘guix system init’. The second part implements the actual test. The new (gnu installer tests) module provides tools to implement a dialogue with the installer, and the new “gui-installed-os” test uses it to perform a bare-bones style installation. There’s a commented out variant that does it on an encrypted root, but it currently fails presumably due to . That’s it! Feedback welcome! Ludo’. PS: This patch series is also available as ‘wip-installer-test’. Ludovic Courtès (7): tests: 'run-basic-test' can enter a root password. installer: Use a Guile-Newt snapshot that supports 'form-watch-fd'. installer: Implement a dialog on /var/guix/installer-socket. installer: Bypass connectivity check when /tmp/installer-assume-online exists. installer: Run commands without hopping through the shell. installer: Honor /tmp/installer-system-init-options. tests: install: Add "gui-installed-os". gnu/installer.scm | 21 ++ gnu/installer/final.scm | 21 +- gnu/installer/newt/final.scm | 40 ++- gnu/installer/newt/network.scm | 10 +- gnu/installer/newt/page.scm | 569 ++++++++++++++++++++----------- gnu/installer/newt/partition.scm | 8 +- gnu/installer/newt/user.scm | 64 ++-- gnu/installer/newt/welcome.scm | 44 ++- gnu/installer/steps.scm | 25 +- gnu/installer/tests.scm | 340 ++++++++++++++++++ gnu/installer/utils.scm | 152 +++++++-- gnu/local.mk | 3 +- gnu/tests/base.scm | 23 +- gnu/tests/install.scm | 200 ++++++++++- 14 files changed, 1212 insertions(+), 308 deletions(-) create mode 100644 gnu/installer/tests.scm