Received: by 2002:a5d:925a:0:0:0:0:0 with SMTP id e26csp824216iol; Thu, 9 Jun 2022 15:04:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJynjl/GMVWeI+HBPTXgYpKvSqdGHsr+vRSQQs99YAqPfWv8t5BKh1057DTyO0+tsUyExRNL X-Received: by 2002:a65:6786:0:b0:3fc:e1c0:7bbc with SMTP id e6-20020a656786000000b003fce1c07bbcmr35299471pgr.65.1654812292489; Thu, 09 Jun 2022 15:04:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654812292; cv=none; d=google.com; s=arc-20160816; b=MfJQbyOTrw6kb8RXEhp3PLSM3omEN/eo2ikwPBHJzJquQp8NN5lj95kyRySK3eznnJ zHim4tYUa7NO/nu7cnnHmAD1uvPEZ8W5yqP8eCJesI9PzKsYyzQ7Fow4tBqt5SW/zkRH IDBhuaY46hUD8M+rniQMgDJTtksPOpTCSAtM3p8tdERro6hwaUwpngCfK7xdFVJ3O0Dd EhLlJomiEPlctVoYbjM2SK4bf0uBugluspGFguHtb2B4ZfgVENLzVFIBUIS96+/sZtGW ayXY4EiVEHIfANc+g3gybLNvud3HjyngiHxvQLD1FEK0+r8+HE8eLMYaxlc+i8XjpTWf hRRw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature:dkim-signature; bh=iRYXycbQVHb8+YRDCK3WyfDOxADDfcwyvcEPl1e9rpM=; b=NTIyAB++LUak2rULlBJgOSCp18wy9s7g7c0JITJAQk6ZmynRREg6Ix9vwfWPqc7bzd 4qFOwNqmQNAataxd5KEn7pxhMaIDz4LSmF2gvk7BNBOHiTfsK+aMerQzPJv179vdsrsQ ZLwT7N1X9lskba16SGksgTjrLq7jRSlLTEn8aGQS5512Sqapd/S8RoRgXYiSeDnZqjUB 9flQabPTzicotfjcRif0WuNATgEYpakefoCGjZD6zsl6aQHSXddkENmQC/z+3IsHksMj 4bTDYBSBqKqZFA3gnUJkzVKTPodyEVopar9UCR7ogEzIF5anQjGMk3fFlNbPdS+GBhKG MAww== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=2J8rrVyU; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x82-20020a627c55000000b005103895dae4si30903890pfc.316.2022.06.09.15.04.18; Thu, 09 Jun 2022 15:04:52 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=2J8rrVyU; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234022AbiFIVml (ORCPT + 99 others); Thu, 9 Jun 2022 17:42:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37276 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239775AbiFIVmi (ORCPT ); Thu, 9 Jun 2022 17:42:38 -0400 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8643C66CB1 for ; Thu, 9 Jun 2022 14:42:35 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 26BC61FEC9; Thu, 9 Jun 2022 21:42:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1654810954; h=from:from:reply-to: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=iRYXycbQVHb8+YRDCK3WyfDOxADDfcwyvcEPl1e9rpM=; b=2J8rrVyUu77q0YnOYu6IeZ9sqXYr8Ir8fBejjzVWAQWSGamlyqvN+7+MTPiqa6jkKTyOtB nXCuS1gs2NU1c2FAK0U2nxHXa857SdSoQUdPCcRDDGBoynxJn3SC/S7/2mXtm0bE78Eud3 R6QBdEA7pBm/kYhu58F3pQoASH1UzF8= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1654810954; h=from:from:reply-to: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=iRYXycbQVHb8+YRDCK3WyfDOxADDfcwyvcEPl1e9rpM=; b=lefvLvPxfH7CyZh7D012fa0YLaE9oIKx5z5uRdrJtVtBMtQqGuTqvWbxzuPBSPYARlm7Kf Ve9aGYBSpgj1lpBg== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id E3F9313A8C; Thu, 9 Jun 2022 21:42:33 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id wC+UNUlpomIQDgAAMHmgww (envelope-from ); Thu, 09 Jun 2022 21:42:33 +0000 From: Petr Vorel To: ltp@lists.linux.it Cc: Petr Vorel , linux-nfs@vger.kernel.org, Cyril Hrubis Subject: [PATCH v2 8/9] shell: Add test for TST_ALL_FILESYSTEMS=1 Date: Thu, 9 Jun 2022 23:42:22 +0200 Message-Id: <20220609214223.4608-9-pvorel@suse.cz> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220609214223.4608-1-pvorel@suse.cz> References: <20220609214223.4608-1-pvorel@suse.cz> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org Unfortunately GitHub Actions don't have loop devices, thus cannot be run in CI: tst_format_device 1 TINFO: timeout per run is 0h 5m 0s /__w/ltp/ltp/lib/tst_device.c:139: TINFO: No free devices found Reviewed-by: Cyril Hrubis Signed-off-by: Petr Vorel --- lib/newlib_tests/shell/tst_all_filesystems.sh | 27 +++++++++++++++++++ testcases/lib/tst_test.sh | 2 +- 2 files changed, 28 insertions(+), 1 deletion(-) create mode 100755 lib/newlib_tests/shell/tst_all_filesystems.sh diff --git a/lib/newlib_tests/shell/tst_all_filesystems.sh b/lib/newlib_tests/shell/tst_all_filesystems.sh new file mode 100755 index 000000000..8509a7481 --- /dev/null +++ b/lib/newlib_tests/shell/tst_all_filesystems.sh @@ -0,0 +1,27 @@ +#!/bin/sh +# SPDX-License-Identifier: GPL-2.0-or-later +# Copyright (c) 2022 Petr Vorel + +TST_ALL_FILESYSTEMS=1 +TST_TESTFUNC=test +TST_CNT=2 + +test1() +{ + tst_res TPASS "device using filesystem" +} + +test2() +{ + local pattern + + + if [ "$TST_FS_TYPE" = "exfat" -o "$TST_FS_TYPE" = "ntfs" ]; then + pattern="|fuseblk" + fi + + EXPECT_PASS "grep -E '$TST_MNTPOINT ($TST_FS_TYPE${pattern})' /proc/mounts" +} + +. tst_test.sh +tst_run diff --git a/testcases/lib/tst_test.sh b/testcases/lib/tst_test.sh index d96ce3448..27f698dab 100644 --- a/testcases/lib/tst_test.sh +++ b/testcases/lib/tst_test.sh @@ -603,7 +603,7 @@ _tst_init_checkpoints() _prepare_device() { if [ "$TST_FORMAT_DEVICE" = 1 ]; then - tst_clear_device $TST_DEVICE + tst_device clear "$TST_DEVICE" tst_mkfs $TST_FS_TYPE $TST_DEV_FS_OPTS $TST_DEVICE $TST_DEV_EXTRA_OPTS fi -- 2.36.1