]> git.saurik.com Git - apt.git/blobdiff - test/integration/test-apt-update-file
drop privileges in copy:// method as we do for file://
[apt.git] / test / integration / test-apt-update-file
index c6e07f8b6b20613b7853d45579a58e0ba2fe98d2..04e26a8f4c1d3e0e557653489e8b856b5535a8a9 100755 (executable)
@@ -19,9 +19,12 @@ insertsource 'unstable' 'foo' 'all' '1'
 setupaptarchive --no-update
 
 # ensure the archive is not writable
-addtrap 'prefix' 'chmod 750 aptarchive/dists/unstable/main/binary-all;'
-chmod 550 aptarchive/dists/unstable/main/binary-all
-
+addtrap 'prefix' 'chmod 755 aptarchive/dists/unstable/main/binary-all;'
+if [ "$(id -u)" = '0' ]; then
+       chmod 550 aptarchive/dists/unstable/main/binary-all
+       testfailure aptget update
+fi
+chmod 555 aptarchive/dists/unstable/main/binary-all
 testsuccess aptget update
 
 # the release files aren't an IMS-hit, but the indexes are