From patchwork Tue Oct 30 00:18:40 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 10660403 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 3103013B5 for ; Tue, 30 Oct 2018 00:20:27 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 258E329A52 for ; Tue, 30 Oct 2018 00:20:27 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 132F829A6A; Tue, 30 Oct 2018 00:20:27 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 6632329A52 for ; Tue, 30 Oct 2018 00:20:26 +0000 (UTC) Received: from localhost ([::1]:49807 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gHHlh-00078w-KD for patchwork-qemu-devel@patchwork.kernel.org; Mon, 29 Oct 2018 20:20:25 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:59799) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gHHkc-000621-Iv for qemu-devel@nongnu.org; Mon, 29 Oct 2018 20:19:19 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gHHkb-00072f-CG for qemu-devel@nongnu.org; Mon, 29 Oct 2018 20:19:18 -0400 Received: from mx1.redhat.com ([209.132.183.28]:36410) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gHHkV-00071T-8v; Mon, 29 Oct 2018 20:19:11 -0400 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 87C3085550; Tue, 30 Oct 2018 00:19:10 +0000 (UTC) Received: from x1w.redhat.com (ovpn-204-38.brq.redhat.com [10.40.204.38]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 0897560BE1; Tue, 30 Oct 2018 00:18:58 +0000 (UTC) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: Peter Maydell Date: Tue, 30 Oct 2018 01:18:40 +0100 Message-Id: <20181030001841.1658-1-philmd@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.28]); Tue, 30 Oct 2018 00:19:10 +0000 (UTC) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.132.183.28 Subject: [Qemu-devel] [PATCH] tests/bios-tables-test: Sanitize test verbose output X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Laurent Vivier , Thomas Huth , "Michael S. Tsirkin" , qemu-devel@nongnu.org, qemu-arm@nongnu.org, Igor Mammedov , Paolo Bonzini , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP Fix the extraneous extra blank lines in the test output when running with V=1. Before: TEST: tests/bios-tables-test... (pid=25678) /i386/acpi/piix4: Looking for expected file 'tests/acpi-test-data/pc/DSDT' Using expected file 'tests/acpi-test-data/pc/DSDT' Looking for expected file 'tests/acpi-test-data/pc/FACP' Using expected file 'tests/acpi-test-data/pc/FACP' Looking for expected file 'tests/acpi-test-data/pc/APIC' Using expected file 'tests/acpi-test-data/pc/APIC' Looking for expected file 'tests/acpi-test-data/pc/HPET' Using expected file 'tests/acpi-test-data/pc/HPET' OK After: TEST: tests/bios-tables-test... (pid=667) /i386/acpi/piix4: Looking for expected file 'tests/acpi-test-data/pc/DSDT' Using expected file 'tests/acpi-test-data/pc/DSDT' Looking for expected file 'tests/acpi-test-data/pc/FACP' Using expected file 'tests/acpi-test-data/pc/FACP' Looking for expected file 'tests/acpi-test-data/pc/APIC' Using expected file 'tests/acpi-test-data/pc/APIC' Looking for expected file 'tests/acpi-test-data/pc/HPET' Using expected file 'tests/acpi-test-data/pc/HPET' OK Suggested-by: Peter Maydell Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Igor Mammedov --- tests/bios-tables-test.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/tests/bios-tables-test.c b/tests/bios-tables-test.c index 4e24930c4b..02dd48de0d 100644 --- a/tests/bios-tables-test.c +++ b/tests/bios-tables-test.c @@ -371,6 +371,9 @@ static GArray *load_expected_aml(test_data *data) gboolean ret; GArray *exp_tables = g_array_new(false, true, sizeof(AcpiSdtTable)); + if (getenv("V")) { + fputc('\n', stderr); + } for (i = 0; i < data->tables->len; ++i) { AcpiSdtTable exp_sdt; gchar *aml_file = NULL; @@ -385,7 +388,7 @@ try_again: aml_file = g_strdup_printf("%s/%s/%.4s%s", data_dir, data->machine, (gchar *)&sdt->header.signature, ext); if (getenv("V")) { - fprintf(stderr, "\nLooking for expected file '%s'\n", aml_file); + fprintf(stderr, "Looking for expected file '%s'\n", aml_file); } if (g_file_test(aml_file, G_FILE_TEST_EXISTS)) { exp_sdt.aml_file = aml_file; @@ -397,7 +400,7 @@ try_again: } g_assert(exp_sdt.aml_file); if (getenv("V")) { - fprintf(stderr, "\nUsing expected file '%s'\n", aml_file); + fprintf(stderr, "Using expected file '%s'\n", aml_file); } ret = g_file_get_contents(aml_file, &exp_sdt.aml, &exp_sdt.aml_len, &error);