2011-11-01 04:24:38 +04:00
#!/bin/bash
#
# Copyright (C) 2011 Colin Walters <walters@verbum.org>
#
2011-11-10 22:17:04 +04:00
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
# version 2 of the License, or (at your option) any later version.
2011-11-01 04:24:38 +04:00
#
2011-11-10 22:17:04 +04:00
# This library is distributed in the hope that it will be useful,
2011-11-01 04:24:38 +04:00
# but WITHOUT ANY WARRANTY; without even the implied warranty of
2011-11-10 22:17:04 +04:00
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Lesser General Public License for more details.
2011-11-01 04:24:38 +04:00
#
2011-11-10 22:17:04 +04:00
# You should have received a copy of the GNU Lesser General Public
# License along with this library; if not, write to the
# Free Software Foundation, Inc., 59 Temple Place - Suite 330,
# Boston, MA 02111-1307, USA.
2011-11-01 04:24:38 +04:00
set -e
2013-07-18 20:09:44 +04:00
echo "1..2"
2011-11-09 17:27:47 +04:00
2013-05-01 23:26:21 +04:00
. $( dirname $0 ) /libtest.sh
2011-11-01 04:24:38 +04:00
2012-09-15 20:44:57 +04:00
setup_test_repository "bare"
2011-11-09 17:27:47 +04:00
$OSTREE checkout test2 checkout-test2
cd checkout-test2
chmod o+x firstfile
2013-07-18 20:09:44 +04:00
$OSTREE fsck -q && ( echo 1>& 2 "fsck unexpectedly succeeded" ; exit 1)
2011-11-09 17:27:47 +04:00
chmod o-x firstfile
$OSTREE fsck -q
2011-11-01 04:24:38 +04:00
2011-11-09 17:27:47 +04:00
echo "ok chmod"
2013-07-18 20:09:44 +04:00
cd ${ test_tmpdir }
rm checkout-test2 -rf
$OSTREE checkout test2 checkout-test2
cd checkout-test2
chmod o+x firstfile
$OSTREE fsck -q --delete && ( echo 1>& 2 "fsck unexpectedly succeeded" ; exit 1)
echo "ok chmod"