Commit Graph

34 Commits

Author SHA1 Message Date
Darrick J. Wong a860a167d8 common: kill _supported_os
fstests only supports Linux, so get rid of this unnecessary predicate.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Eryu Guan <guaneryu@gmail.com>
2020-09-21 01:16:50 +08:00
Dave Chinner f3faa8173a fstests: convert new test template to SPDX tags
Signed-off-by: Dave Chinner <dchinner@redhat.com>
2018-06-09 11:35:32 +10:00
Jan Kara 141bd37a36 fstests: Make ./new work for non-root user
Currently 'new' script sources common/config which tries to find
mkfs and fails if not found (which is likely for non-root user).
This is inconvenient as development usually does not happen as root.
In fact the vast majority of setup in common/config and common/rc is
not necessary for 'new'. Split out the necessary bits into new
common/test_names and use it in 'new'. Cleanup common/rc and
common/config now that they're only used from 'check' and 'setup'.

Signed-off-by: Jan Kara <jack@suse.cz>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Eryu Guan <guaneryu@gmail.com>
2018-06-03 22:16:15 +08:00
Eryu Guan 9c129c6887 new: validate groups when creating new test
Allow only lower case letters, digits, spaces and underscore when
adding groups, give prompt if there's any not-allowed characters.
Also remove redundant spaces between groups.

Reviewed-by: Brian Foster <bfoster@redhat.com>
Signed-off-by: Eryu Guan <eguan@redhat.com>
2017-08-03 20:44:04 +08:00
Qu Wenruo 073b2def71 fstests: Remove IRIX os support from template
Since the last release of IRIX is already 10 years ago and support
for it has ended after 2014, there is no need to support IRIX any
way.

Signed-off-by: Qu Wenruo <quwenruo@cn.fujitsu.com>
Reviewed-by: David Disseldorp <ddiss@suse.de>
Signed-off-by: Eryu Guan <eguan@redhat.com>
2017-04-06 20:49:37 +08:00
Eryu Guan 042dad6267 new: create a default .out file
Creating a default .out file in "new" to ease the new test creation
process.

Signed-off-by: Eryu Guan <eguan@redhat.com>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
2016-02-08 09:27:14 +11:00
Qu Wenruo ccdcf1236c new: Add seqres.full cleanup to template
Add cleanup for seqres.full for new test case template, as sometimes
new testcase may forgot to cleanup seqres.full.

Signed-off-by: Qu Wenruo <quwenruo@cn.fujitsu.com>
2015-09-21 13:06:18 +10:00
Jan Tulak 03c633bff6 build: Allow alphanumeric test name suffixes
To allow test names to be more descriptive, allow a suffix to be
added to the numeric name of the test.  e.g. a test can be named
"tests/generic/001-some-descriptive-name".

Name suffixes are limited to alphanumeric characters and dash - the
name is always prefixed with an unique id for easy identification
of a specific test. Hence we can still use shorthand forms such as
"generic/001" when referring to a test and be clearly understood.

Signed-off-by: Jan Tulak <jtulak@redhat.com>
Reviewed-by: Eryu Guan <eguan@redhat.com>
Reviewed-by: David Sterba <dsterba@suse.cz>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
2015-04-02 09:23:10 +11:00
Eryu Guan d3d25b0cd4 new: fix template for new case to use a single tab not four spaces
So we have preferred code style for all new test cases.

Signed-off-by: Eryu Guan <eguan@redhat.com>
Reviewed-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
2015-03-18 14:57:33 +11:00
Dmitry Monakhov fd730cff44 fstests: update 'new' script
- Update script to support new test cheme tests/$fs_type/$TEST_IDX
- Try to use first unused ID

Signed-off-by: Dmitry Monakhov <dmonakhov@openvz.org>
Reviewed-by: Eryu Guan <eguan@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
2014-11-10 18:01:10 +11:00
Lukas Czerner 83ef157def common: Check fs consistency on TEST_DEV only when needed
Currently we're checking file system consistency on TEST_DEV after every
successful test run even though the TEST_DEV might not even be used in
that test.

Fix it by introducing _require_test to for the test ti indicate that
it's about to use TEST_DEV.

Also add _require_test to the new script so that this requirement is a
default.

Signed-off-by: Lukas Czerner <lczerner@redhat.com>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
2014-08-13 11:08:41 +10:00
Eryu Guan 17ecca6b12 xfstests: remove comments about creator in new
We have removed creator/owner info from each test case, remove the
'creator' comment in template too.

Signed-off-by: Eryu Guan <eguan@redhat.com>
Reviewed-by: Rich Johnston <rjohnston@sgi.com>
Signed-off-by: Rich Johnston <rjohnston@sgi.com>
2013-04-10 07:04:27 -05:00
Eryu Guan d1ec02af9e xfstests: set correct seqres variable in new when creating test template
When setting seqres in the new script, '$' should be escaped,
otherwise seqres will be set to '/' not '$RESULT_DIR/$seq'

Signed-off-by: Eryu Guan <eguan@redhat.com>
Reviewed-by: Rich Johnston <rjohnston@sgi.com>
Signed-off-by: Rich Johnston <rjohnston@sgi.com>
2013-04-01 08:16:37 -05:00
Eryu Guan 8575764a79 xfstests: fix common source file path
After the re-factor, common.* have been renamed to common/* but there
are several files still look for the old path, fix it.

Signed-off-by: Eryu Guan <eguan@redhat.com>
Reviewed-by: Rich Johnston <rjohnston@sgi.com>
Signed-off-by: Rich Johnston <rjohnston@sgi.com>
2013-03-29 10:09:35 -05:00
Dave Chinner 1d5d46db80 xfstests: convert tests to use new results directory
Essentially the change is simply this. Converting:

... >> $seq.????

to:

.... >> $RESULT_DIR/$seq.????

so that output files are directed to the defined output directory.

sed to the rescue:

$ sed -i -e '/^seq=.*$/a seqres=$RESULT_DIR/$seq' -e 's/seq.full/seqres.full/' tests/*/*

will do most of the work automatically.

Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Phil White <pwhite@sgi.com>
[rjohnston@sgi.com reworked for TOT changes]
Signed-off-by: Rich Johnston <rjohnston@sgi.com>
2013-03-26 21:38:47 -05:00
Dave Chinner 0925cbea74 xfstests: kill useless test owner fields
Back many years ago, the owner field was used to email the test
owner when auto-qa failed that test. It is not needed anymore - if
you want to know who wrote the test, look it up in git....

Script used was:

$ sed -i -e "/^# creator/d" -e "/^owner/d" [0-3][0-9][0-9]

Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Phil White <pwhite@sgi.com>
[rjohnston@sgi.com added TOT changes]
Signed-off-by: Rich Johnston <rjohnston@sgi.com>
2013-03-26 10:33:58 -05:00
Dave Chinner fa6a7868cd xfsqa: more sh to bash conversions
A new test is using /bin/sh and failing on debian. Clean it up and all the
remaining uses of /bin/sh.

Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
2010-04-29 09:59:24 +10:00
Christian Kujau 3ba1b10a87 don't fail if nslookup is not found
When nslookup is not available, execution would stop. This patch moves the
check for nslookup and the _get_fqdn function into the ./new script (since
this is the only place where it's used) and we don't fail any more but try
to find out our FQDN without nslookup.

Signed-off-by: Christian Kujau <lists@nerdbynature.de>
Signed-off-by: Christoph Hellwig <hch@lst.de>
2009-07-20 11:31:39 +02:00
Eric Sandeen aec4f29390 Make "new" script insert appropriate license on tests
Don't default to SGI copyright, someone else may be
making this test...

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
2009-06-05 17:07:20 -05:00
Felix Blyakher 491d467f3c Add GPL license plate to SGI's files.
Signed-off-by: Felix Blyakher <felixb@sgi.com>
Reviewed-by: Eric Sandeen <sandeen@sandeen.net>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Felix Blyakher <felixb@sgi.com>
2009-06-05 15:41:14 -05:00
Eric Sandeen 7737a5d7fb Support "generic" filesystem type
Create a new "generic" _supported_fs type for tests
which are not really filesystem-specific.  "generic"
tests do expect that acl & attr are supported though.

Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
Reviewed-by: Christoph Hellwig <hch@lst.de>
2009-05-28 11:37:38 -05:00
David Disseldorp db395db976 fix group listing regexp
Merge of master-melb:xfs-cmds:28513a by kenmcd.

  add dmapi group
2007-05-04 06:10:34 +00:00
Nathan Scott 640164847a Update copyright annotations and license boilerplates to correspond with SGI Legals preferences.
Merge of master-melb:xfs-cmds:24327a by kenmcd.
2005-11-09 02:49:08 +00:00
Andrew Jones 6bf85bc85e Rewrote test 068, test to to reproduce xfs_freeze hang under filsystem load.
Merge of master-melb:xfs-cmds:21434a by kenmcd.

  Rewrote test 068. Test case to reproduce xfs_freeze hang under filsystem load.
2005-02-09 02:49:23 +00:00
ptools 048a7a8add More merge conflicts 2004-06-15 07:36:09 +00:00