From 492f011795cff3ba6a27ab04b02e781c7fb5513e Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Thu, 20 Jul 2006 10:30:42 +0000 Subject: (file-type): New test: For 5.97 and earlier, --file-type acted like --indicator-style=slash. --- tests/ls-2/tests | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'tests/ls-2') diff --git a/tests/ls-2/tests b/tests/ls-2/tests index bb5f39c45..71c3fa78c 100755 --- a/tests/ls-2/tests +++ b/tests/ls-2/tests @@ -1,4 +1,5 @@ #!/bin/sh +# -*- perl -*- : ${PERL=perl} : ${srcdir=.} @@ -31,6 +32,11 @@ my $slink_d = {PRE => sub {symlink '/', 'd' or die "d: $!\n"; }}; my $unlink_d = {POST => sub {unlink 'd' or die "d: $!\n"}}; +my $mkdir_d_slink = {PRE => sub {mkdir 'd',0755 or die "d: $!\n"; + symlink '/', 'd/s' or die "d/s: $!\n" }}; +my $rmdir_d_slink = {POST => sub {unlink 'd/s' or die "d/s: $!\n"; + rmdir 'd' or die "d: $!\n" }}; + sub make_j_d () { mkdir 'j', 0700 or die "creating j: $!\n"; @@ -126,6 +132,10 @@ my @Tests = unlink qw(setuid setgid); foreach my $dir (qw(owr owt sticky)) {rmdir $dir} }}, ], + + # For 5.97 and earlier, --file-type acted like --indicator-style=slash. + ['file-type', '--file-type d', {OUT => "s@\n"}, + $mkdir_d_slink, $rmdir_d_slink], ); my $save_temps = $ENV{SAVE_TEMPS}; -- cgit v1.2.3-70-g09d2