mirror of
git://git.sv.gnu.org/coreutils.git
synced 2026-03-03 11:40:04 +02:00
* tests/README: Remove long-obsolete file. * tests/Makefile.am (EXTRA_DIST): Remove README. * tests/misc/truncate-dir-fail: Add copyright comment. * tests/misc/selinux: Likewise. * tests/misc/chcon: Likewise. * tests/misc/chcon-fail: Likewise. * tests/sample-test: Use only 2010 in this list.
30 lines
902 B
Bash
Executable File
30 lines
902 B
Bash
Executable File
#!/bin/sh
|
|
# Make sure truncate fails for a directory.
|
|
|
|
# Copyright (C) 2008-2010 Free Software Foundation, Inc.
|
|
|
|
# This program is free software: you can redistribute it and/or modify
|
|
# it under the terms of the GNU General Public License as published by
|
|
# the Free Software Foundation, either version 3 of the License, or
|
|
# (at your option) any later version.
|
|
|
|
# This program is distributed in the hope that it will be useful,
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
# GNU General Public License for more details.
|
|
|
|
# You should have received a copy of the GNU General Public License
|
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
if test "$VERBOSE" = yes; then
|
|
set -x
|
|
truncate --version
|
|
fi
|
|
|
|
. $srcdir/test-lib.sh
|
|
|
|
# truncate on dir not allowed
|
|
truncate -s+0 . && fail=1
|
|
|
|
Exit $fail
|