JRE-458 added new regression test (Insufficient and inconsistent permissions on some files in Linux build)

(cherry picked from commit 82adbe9c25)
This commit is contained in:
Vitaly Provodin
2018-11-23 17:10:37 +07:00
committed by alexey.ushakov@jetbrains.com
parent 2ccb86eec8
commit 7e660c569c

View File

@@ -0,0 +1,22 @@
#!/usr/bin/env bash
# @test
# @summary permissions458.sh checks readability permissions of JDK build
# @run shell permissions458.sh
if [ -z "${TESTJAVA}" ]; then
echo "TESTJAVA undefined: testing cancelled"
exit 1
fi
FIND="/usr/bin/find"
files=$(${FIND} ${TESTJAVA} -not -perm -444)
if [ $? != 0 ]; then
echo "Command failed."
exit 1
elif [ "$files" ]; then
echo "Files with no readability permissions:"
ls -l $files
echo "\nTest failed"
exit 1
fi