[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: tests/du/ what's the rationale?

From: Pádraig Brady
Subject: Re: tests/du/ what's the rationale?
Date: Sun, 20 Jan 2013 12:34:28 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20120615 Thunderbird/13.0.1

On 01/20/2013 12:31 PM, Bernhard Voelker wrote:
On 01/20/2013 12:01 PM, Pádraig Brady wrote:
On 01/19/2013 10:33 PM, Bernhard Voelker wrote:
Does anyone remember the reason for adding this test?

    # Ensure that the size of a long-named-symlink is > 0.

I guess the rationale is to verify the symlink is not being resolved,
though you're right that symlink allocation is dependent on the
file system.

Thanks, yes, that sounds reasonable.

I suppose one could use a loopback ext2 file system
like in cp/

Probably, but this would require_root_, of course.
BTW: interestingly, it would fail on a loop-mounted EXT2 file system
(all the created links have 0 size there) while it would work on EXT4.

heh interesting

Wouldn't it then be better to make the test positive, i.e. prove that
a symlink which points to a 10k file does not show up as 10k in du?
... but stop, reading through tests/du, we have such tests already:
   * tests/
   * tests/du/
   * tests/du/
All 3 tests above prove that dereferencing or not-dereferencing works

That makes me come to my initial question:

Is tests/du/ obsolete nowadays?

That test is problematic with various file systems, and the original
test case is already covered by other tests. I'd tend to simply
remove it.


thanks for the detailed anlaysis,

reply via email to

[Prev in Thread] Current Thread [Next in Thread]