<feed xmlns='http://www.w3.org/2005/Atom'>
<title>coreutils/tests/du, branch v8.22</title>
<subtitle>Mirror of https://https.git.savannah.gnu.org/git/coreutils.git/
</subtitle>
<id>https://git.shady.money/coreutils/atom?h=v8.22</id>
<link rel='self' href='https://git.shady.money/coreutils/atom?h=v8.22'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/coreutils/'/>
<updated>2013-07-28T23:51:55Z</updated>
<entry>
<title>tests: fix another test failure in test/du/inodes.sh</title>
<updated>2013-07-28T23:51:55Z</updated>
<author>
<name>Bernhard Voelker</name>
<email>mail@bernhard-voelker.de</email>
</author>
<published>2013-07-28T23:51:55Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/coreutils/commit/?id=eea81b46cd1dc06c964adfc9a2ee15de6a2ddeee'/>
<id>urn:sha1:eea81b46cd1dc06c964adfc9a2ee15de6a2ddeee</id>
<content type='text'>
Prompted by the continuous integration build failure at:
http://hydra.nixos.org/build/5584121

du(1) uses the first file object of the two test files linked to the
same inode, 'd/f' and 'd/h', whatever the system returns first.
Use 'd/f' in both the expected and the actual output.

* test/du/inodes.sh: Change the expected output as described above
when returning the --all directory entries (without -l).  Also replace
the name of the hardlink 'd/h' by 'd/f' in the actual output.
</content>
</entry>
<entry>
<title>maint: cleanup compare calls in test/du/inodes.sh</title>
<updated>2013-07-28T16:32:22Z</updated>
<author>
<name>Bernhard Voelker</name>
<email>mail@bernhard-voelker.de</email>
</author>
<published>2013-07-28T16:32:22Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/coreutils/commit/?id=9e52ebac5793dfed309a5ae97ab753f000e93f00'/>
<id>urn:sha1:9e52ebac5793dfed309a5ae97ab753f000e93f00</id>
<content type='text'>
* test/du/inodes.sh: In the cases where compare() fails, that function
would show the unified diff automatically.  Therefore, remove the
excess "cat out".
In the cases where expecting an empty file, use compare() again
rather than the simpler "test -s" because possible error reports
will then include the file's content for the same reason as above.
</content>
</entry>
<entry>
<title>tests: fix intermittent failure in test/du/inodes.sh</title>
<updated>2013-07-27T23:26:57Z</updated>
<author>
<name>Pádraig Brady</name>
<email>P@draigBrady.com</email>
</author>
<published>2013-07-27T23:19:45Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/coreutils/commit/?id=012fbb63719f4a683604c4917a34d2039e38c023'/>
<id>urn:sha1:012fbb63719f4a683604c4917a34d2039e38c023</id>
<content type='text'>
Prompted by the continuous integration build failure at:
http://hydra.nixos.org/build/5582213

* test/du/inodes.sh: Due to undefined order in returned directory
entries, the expected output might not match, so sort both expected
and actual output when returning --all directory entries.
Also use a simpler test for ensuring no errors are output.
</content>
</entry>
<entry>
<title>du: add --inodes option</title>
<updated>2013-07-27T12:25:28Z</updated>
<author>
<name>Bernhard Voelker</name>
<email>mail@bernhard-voelker.de</email>
</author>
<published>2013-07-27T12:25:28Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/coreutils/commit/?id=333dc83d52e014a0b532e316ea8cd93b048f1ac6'/>
<id>urn:sha1:333dc83d52e014a0b532e316ea8cd93b048f1ac6</id>
<content type='text'>
This new option can be used to find directories with a huge
amount of files.  The GNU find utility has the printf format
"%h" which prints the number of entries in a directory, but
this is non-cumulative and doesn't handle hard links.

* src/du.c (struct duinfo): Add new member for counting inodes.
(duinfo_init): Initialize inodes member with Zero.
(duinfo_set): Set inodes counter to 1.
(duinfo_add): Sum up the 2 given inodes counters.
(opt_inodes): Add new boolean flag to remember if the --inodes
option has been specified.
(INODES_OPTION): Add new enum value to be used ...
(long_options): ... here.
(usage): Add description of the new option.
(print_size): Pass inodes counter or size to print_only_size,
depending on the inodes mode.
(process_file): Adapt threshold handling: with --inodes, print or
elide the entries according to the struct member inodes.
(main): Add a case for accepting the new INODES_OPTION.
Print a warning diagnostic when --inodes is used together with the
option --apparent-size or -b.
Reset the output_block_size to 1 ... and thus ignoring the
options -m and -k.
* tests/du/inodes.sh: Add a new test.
* tests/local.mk (all_tests): Mention it.
* doc/coreutils.texi (du invocation): Document the new option.
* NEWS: Mention the new option.
</content>
</entry>
<entry>
<title>maint: make some shell and perl scripts executable in 'tests/'</title>
<updated>2013-07-21T23:07:52Z</updated>
<author>
<name>Bernhard Voelker</name>
<email>mail@bernhard-voelker.de</email>
</author>
<published>2013-07-21T23:07:52Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/coreutils/commit/?id=0c452fe97a395a1ecc2cacce3609ea6be366ac8e'/>
<id>urn:sha1:0c452fe97a395a1ecc2cacce3609ea6be366ac8e</id>
<content type='text'>
Some newer test scripts - partially ones from me - are not executable.
It does not seem to be a problem, but for consistency and to avoid
future problems on unusual platforms or shells change the permissions
by adding the executable bit.

* cfg.mk (sc_tests_executable): Add new syntax-check rule to ensure
that all test scripts are executable.
* tests/df/df-output.sh: Change file mode from 644 to 755.
* tests/du/threshold.sh: Likewise.
* tests/factor/run.sh: Likewise.
* tests/init.sh: Likewise.
* tests/misc/csplit-suppress-matched.pl: Likewise.
* tests/misc/numfmt.pl: Likewise.
* tests/tail-2/retry.sh: Likewise.
</content>
</entry>
<entry>
<title>tests: avoid false failures on file systems with smaller NAME_MAX</title>
<updated>2013-02-20T04:04:00Z</updated>
<author>
<name>Pádraig Brady</name>
<email>P@draigBrady.com</email>
</author>
<published>2013-02-19T12:06:18Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/coreutils/commit/?id=b469fa044a81762a9eb0da92b4fb47467154c4f1'/>
<id>urn:sha1:b469fa044a81762a9eb0da92b4fb47467154c4f1</id>
<content type='text'>
* tests/du/long-from-unreadable.sh: This test requires a NAME_MAX
of at least 200, so skip the test otherwise.
* tests/rm/deep-2.sh: Likewise.
Reported by C de-Avillez with ecryptfs where NAME_MAX = 143.
</content>
</entry>
<entry>
<title>tests: avoid non portable sed use of \t</title>
<updated>2013-02-14T14:49:31Z</updated>
<author>
<name>Pádraig Brady</name>
<email>P@draigBrady.com</email>
</author>
<published>2013-02-14T04:27:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/coreutils/commit/?id=4f03385e9b96e163bed1fbbb8d63aeeb5fac4e90'/>
<id>urn:sha1:4f03385e9b96e163bed1fbbb8d63aeeb5fac4e90</id>
<content type='text'>
* tests/du/threshold.sh: use `cut` rather than
sed to avoid using the non portable \t which
fails on sed on openbsd 5 at least.
Also remove a redundant call to `tr` and avoid
explicit setting of LANG=C which is done globally.
</content>
</entry>
<entry>
<title>du: add -t SIZE, --threshold=SIZE option</title>
<updated>2013-01-21T10:38:54Z</updated>
<author>
<name>Jakob Truelsen</name>
<email>jakob@scalgo.com</email>
</author>
<published>2013-01-21T05:29:12Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/coreutils/commit/?id=f8afbb424c050578617bc9ddf4ccf69ed2bdb953'/>
<id>urn:sha1:f8afbb424c050578617bc9ddf4ccf69ed2bdb953</id>
<content type='text'>
* src/du.c (opt_threshold): Add variable to hold the value of
the --threshold option specified by the user.
(long_options): Add a required_argument entry for the new
--threshold option.
(usage): Add --threshold option.
(process_file): Elide printing the entry if its size does not
meet the value specified by the --threshold option.
(main): In the argument parsing loop, add a case for the new
-t option. Convert the given argument by permitting the
well-known suffixes for megabyte, gigabytes, etc.
Handle the special case "-0": give an error as this value is
not permitted.
* doc/coreutils.texi (du invocation): Add documentation for the
above new option.
* tests/du/threshold.sh: Add new test to exercise the new option.
* tests/local.mk (all_tests): Mention the above test.

Co-authored-by: Bernhard Voelker &lt;mail@bernhard-voelker.de&gt;
</content>
</entry>
<entry>
<title>tests: remove test case du/slink</title>
<updated>2013-01-20T22:47:32Z</updated>
<author>
<name>Bernhard Voelker</name>
<email>mail@bernhard-voelker.de</email>
</author>
<published>2013-01-20T22:47:32Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/coreutils/commit/?id=40b2770a22828e347c9ff0640f4ee0702319e8e7'/>
<id>urn:sha1:40b2770a22828e347c9ff0640f4ee0702319e8e7</id>
<content type='text'>
This test tried to ensure that not all symlinks (across all
file system types) have Zero size and refers to a change
in system.h from 2002-08-31 (commit SH-UTILS-2_0_15-55-g62808a7).
The test used to do this by working on symlinks to long file
names.  This assumption is dependant on the underlying file
system, and in some environments like XEN does not even work
on file systems known to work otherwise.

The test for dereferencing and no-dereferencing symlinks is
already covered by other tests (du/deref.sh, du/deref-args.sh,
and du/no-deref.sh).  Therefore, remove it.

* tests/du/slink.sh: Remove file.
* tests/local.mk (all_tests): Remove the above test.

Discussed in:
http://lists.gnu.org/archive/html/coreutils/2013-01/msg00053.html
</content>
</entry>
<entry>
<title>maint: update all copyright year number ranges</title>
<updated>2013-01-01T03:51:20Z</updated>
<author>
<name>Jim Meyering</name>
<email>jim@meyering.net</email>
</author>
<published>2013-01-01T02:54:51Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/coreutils/commit/?id=77da73c75432f3c5b4beebae7b0797a1e33160bc'/>
<id>urn:sha1:77da73c75432f3c5b4beebae7b0797a1e33160bc</id>
<content type='text'>
Run "make update-copyright", but then also run this,
  perl -pi -e 's/2\d\d\d-//' tests/sample-test
to make that one script use the single most recent year number.
</content>
</entry>
</feed>
