]> git.apps.os.sepia.ceph.com Git - xfstests-dev.git/commit
xfstests: 310 fails with existing directory error
authorDave Chinner <dchinner@redhat.com>
Wed, 1 May 2013 08:32:00 +0000 (08:32 +0000)
committerRich Johnston <rjohnston@sgi.com>
Fri, 3 May 2013 14:22:12 +0000 (09:22 -0500)
commit97540f14f71e6785838532a982c443571380cfcc
tree56db4010bfb00e74ceace7132ad49fed89e6e5da
parent87f5e8e2dbf02b3c4d804a797ed5a7a643f4b64e
xfstests: 310 fails with existing directory error

Test 310 fails with:

mkdir: cannot create directory `/mnt/test/tmp': File exists

$TEST_DIR is persistent, so test directories need to be created with
"mkdir -p" so they don't fail if the directory already exists.

Many other things need fixing, too.
- Tests should define directories they use on $TEST_DIR by
  their sequence number, not generic names.

- Use a variable for the directory the test runs in
  ($SEQ_DIR, in this case) to avoid having to manually code
  it everywhere.

- New binaries need to be added to .gitignore.

- Return status for shell functions is 0 for success,
  non-zero for failure.

- Setting status=0 if there is no failure in the first test
  means that even if the second test fails, the test will
  still pass. Change the test to use "_fatal" when a kernel
  bug is detected, and only set status=0 when the entire
  test has finished.

- reduce the default runtime by to roughly a minute and
  scale it with the stress load factor variables. In most
  cases, this test is never going to hit problems (as
  they've already been fixed) so running it for ~4 minutes
  is mostly a waste of time...

Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Rich Johnston <rjohnston@sgi.com>
Signed-off-by: Rich Johnston <rjohnston@sgi.com>
.gitignore
tests/generic/310