xfs
[Top] [All Lists]

Re: [PATCH] xfstests: fix the regex pattern in get_group_list of check

To: Dave Chinner <david@xxxxxxxxxxxxx>
Subject: Re: [PATCH] xfstests: fix the regex pattern in get_group_list of check
From: Wang Sheng-Hui <shhuiw@xxxxxxxxx>
Date: Sat, 13 Apr 2013 00:38:36 +0800
Cc: Rich Johnston <rjohnston@xxxxxxx>, Dave Chinner <dchinner@xxxxxxxxxx>, xfstests <xfs@xxxxxxxxxxx>
Delivered-to: xfs@xxxxxxxxxxx
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:message-id:date:from:user-agent:mime-version:to:cc :subject:references:in-reply-to:content-type :content-transfer-encoding; bh=doZ25VAv8XWzUKZPLH1NWB1bdDxrruwvfewVlkKk8hc=; b=pyx/pKVYU8atMoX4MlJGqHEFT7p5ApUj5h4sOX+7WrFBCPmOgK7AEnmJPxvuH7eZfX bayMuhk8Zdm0fWBslNn3iCxh/khYvqb3gMQgcuycduNWokD4En0ETpA2yc6jh28pE6kk CgCuNvJfbFQwc1AIJJyg4tFPA1rAjcQWC3/gnPDzV0xRge3P+bDHqthXN6zbuJugShxx dDX3yyC3I74fpmmW6YXyU+laGH9eAzZSYx2MbBRxKT/glGu+Mn6Lw2109+2QOOjct3Vs jhKrpcZSv7GJpHOXkaLJnfkJMF2YmvlepfWzzMpz3w8Ek65nHH2WGZBriuHkGzrmDX/z FHrQ==
In-reply-to: <20130412075728.GD30622@dastard>
References: <5167A5D3.4070903@xxxxxxxxx> <20130412075728.GD30622@dastard>
User-agent: Mozilla/5.0 (X11; Linux i686; rv:17.0) Gecko/17.0 Thunderbird/17.0
On 2013å04æ12æ 15:57, Dave Chinner wrote:
On Fri, Apr 12, 2013 at 02:12:35PM +0800, Wang Sheng-Hui wrote:
In group files, non comment line starts with a 3-digits, then followed by
space and other characters, but no group names.

I don't follow. A group file line looks like:

003 db auto quick

Which defines the test name, followed by the group names the test
belongs to.

The old regex in get_group_list uses the group name as part of the regex,
and fails './check -g xfs' run:
         Group "xfs" is empty or not defined?

Well, yes, "xfs" is not a defined group name:

$ grep xfs tests/*/group
$

If I define a "xfs" group by assigning tests to it, check runs just
fine.

$ grep xfs tests/*/group
tests/xfs/group:003 db auto quick xfs
$ sudo ./check -g xfs
FSTYP         -- xfs (debug)
PLATFORM      -- Linux/x86_64 test-2 3.9.0-rc4-dgc+
MKFS_OPTIONS  -- -f -bsize=4096 /dev/vdb
MOUNT_OPTIONS -- /dev/vdb /mnt/scratch

xfs/003  1s
Ran: xfs/003
Passed all 1 tests
$

So what check is doing looks perfectly OK to me and doesn't need
changing.

The patch removes the pattern for group name, and thus we can trigger tests
like "./check -g xfs" as normal.

If you want to run all the tests in a specific subdirectory regardless
of groups, then you can do it like:

$ sudo ./check xfs/[0-9][0-9][0-9]

Thanks, Dave.

I confused the group with fs type.

FSTYP         -- xfs (debug)
PLATFORM      -- Linux/x86_64 test-2 3.9.0-rc4-dgc+
MKFS_OPTIONS  -- -f -bsize=4096 /dev/vdb
MOUNT_OPTIONS -- /dev/vdb /mnt/scratch

xfs/003  0s
xfs/004  0s
xfs/008  1s
.....

There's definitely better ways to do this, but conflating source tree
layout with runtime test group definitions is not it. ;)

Perhaps something like "check xfs" will just run all tests in the
xfs test dir, similar for ext4, shared, etc?

Cheers,

Dave.


<Prev in Thread] Current Thread [Next in Thread>