]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
du: tests: make H_flag tests more strict about output requirements
authorKyle Evans <kevans@FreeBSD.org>
Tue, 5 Jan 2021 21:49:46 +0000 (15:49 -0600)
committerKyle Evans <kevans@FreeBSD.org>
Sun, 24 Jan 2021 04:05:00 +0000 (22:05 -0600)
commitad62ba026e4d91f01569ca17f3b9f900a60cc08f
treeb6bc3c5803ac1cc11bf05be58e0986efa8d33649
parent4b74a4d4e26788ae8e47ec10172ac80ce435dbb5
du: tests: make H_flag tests more strict about output requirements

The current version of this test will effectively pass as long as one of the
specified paths is in the output, and it could even be a subset of one of
the paths.

Strengthen up the test a little bit:
  * Specify beginning/end anchors for each path
  * Add egrep -v checks to make sure we don't have any *additional* paths
  * Ratchet down paths2 to exactly the two paths we expect to appear

(cherry picked from commit 3c5c39c7ad8f010cfa5fc0db43d15d1964b4cf16)
usr.bin/du/tests/du_test.sh