Run passing tests from pjdfstest

This downloads a tarball by hash instead of using a submodule.
References #1589.
This commit is contained in:
Andrew Gaul 2023-08-22 23:17:43 +09:00
parent 01189e99fc
commit 47661e575a
4 changed files with 61 additions and 5 deletions

View File

@ -146,7 +146,7 @@ elif [ "${CONTAINER_FULLNAME}" = "rockylinux:9" ]; then
#
PACKAGE_INSTALL_ADDITIONAL_OPTIONS="--allowerasing"
INSTALL_PACKAGES="clang-tools-extra curl-devel fuse fuse-devel gcc libstdc++-devel gcc-c++ glibc-langpack-en java-17-openjdk-headless jq libxml2-devel mailcap git automake make openssl openssl-devel attr diffutils curl python3 procps unzip xz https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm"
INSTALL_PACKAGES="clang-tools-extra curl-devel fuse fuse-devel gcc libstdc++-devel gcc-c++ glibc-langpack-en java-17-openjdk-headless jq libxml2-devel mailcap git automake make openssl openssl-devel perl-Test-Harness attr diffutils curl python3 procps unzip xz https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm"
INSTALL_CHECKER_PKGS="cppcheck"
INSTALL_CHECKER_PKG_OPTIONS="--enablerepo=epel"
@ -160,7 +160,7 @@ elif [ "${CONTAINER_FULLNAME}" = "rockylinux:8" ]; then
PACKAGE_UPDATE_OPTIONS="update -y -qq"
PACKAGE_INSTALL_OPTIONS="install -y"
INSTALL_PACKAGES="clang-tools-extra curl-devel fuse fuse-devel gcc libstdc++-devel gcc-c++ glibc-langpack-en java-17-openjdk-headless jq libxml2-devel mailcap git automake make openssl openssl-devel attr diffutils curl python3 unzip"
INSTALL_PACKAGES="clang-tools-extra curl-devel fuse fuse-devel gcc libstdc++-devel gcc-c++ glibc-langpack-en java-17-openjdk-headless jq libxml2-devel mailcap git automake make openssl openssl-devel perl-Test-Harness attr diffutils curl python3 unzip"
INSTALL_CHECKER_PKGS="cppcheck"
INSTALL_CHECKER_PKG_OPTIONS="--enablerepo=powertools"
@ -188,7 +188,7 @@ elif [ "${CONTAINER_FULLNAME}" = "fedora:38" ]; then
PACKAGE_UPDATE_OPTIONS="update -y -qq"
PACKAGE_INSTALL_OPTIONS="install -y"
INSTALL_PACKAGES="clang-tools-extra curl-devel fuse fuse-devel gcc libstdc++-devel gcc-c++ glibc-langpack-en java-latest-openjdk-headless jq libxml2-devel mailcap git automake make openssl openssl-devel curl attr diffutils procps python3-pip unzip"
INSTALL_PACKAGES="clang-tools-extra curl-devel fuse fuse-devel gcc libstdc++-devel gcc-c++ glibc-langpack-en java-latest-openjdk-headless jq libxml2-devel mailcap git automake make openssl openssl-devel perl-Test-Harness curl attr diffutils procps python3-pip unzip"
INSTALL_CHECKER_PKGS="cppcheck ShellCheck"
INSTALL_CHECKER_PKG_OPTIONS=""
@ -197,7 +197,7 @@ elif [ "${CONTAINER_FULLNAME}" = "fedora:37" ]; then
PACKAGE_UPDATE_OPTIONS="update -y -qq"
PACKAGE_INSTALL_OPTIONS="install -y"
INSTALL_PACKAGES="clang-tools-extra curl-devel fuse fuse-devel gcc libstdc++-devel gcc-c++ glibc-langpack-en java-latest-openjdk-headless jq libxml2-devel mailcap git automake make openssl openssl-devel curl attr diffutils procps python3-pip unzip"
INSTALL_PACKAGES="clang-tools-extra curl-devel fuse fuse-devel gcc libstdc++-devel gcc-c++ glibc-langpack-en java-latest-openjdk-headless jq libxml2-devel mailcap git automake make openssl openssl-devel perl-Test-Harness curl attr diffutils procps python3-pip unzip"
INSTALL_CHECKER_PKGS="cppcheck ShellCheck"
INSTALL_CHECKER_PKG_OPTIONS=""
@ -215,7 +215,7 @@ elif [ "${CONTAINER_FULLNAME}" = "alpine:3.17" ]; then
PACKAGE_UPDATE_OPTIONS="update --no-progress"
PACKAGE_INSTALL_OPTIONS="add --no-progress --no-cache"
INSTALL_PACKAGES="bash clang-extra-tools curl g++ make automake autoconf libtool git curl-dev fuse-dev jq libxml2-dev openssl coreutils procps attr sed mailcap openjdk17 aws-cli"
INSTALL_PACKAGES="bash clang-extra-tools curl g++ make automake autoconf libtool git curl-dev fuse-dev jq libxml2-dev openssl coreutils procps attr sed mailcap openjdk17 perl-test-harness-utils aws-cli"
INSTALL_CHECKER_PKGS="cppcheck shellcheck"
INSTALL_CHECKER_PKG_OPTIONS=""

3
.gitignore vendored
View File

@ -82,8 +82,11 @@ src/s3fs
src/test_curl_util
src/test_page_list
src/test_string_util
test/chaos-http-proxy-*
test/junk_data
test/pjdfstest
test/pjd-pjdfstest-*
test/s3proxy-*
test/write_multiblock
test/mknod_test

View File

@ -94,6 +94,8 @@ S3PROXY_BINARY="${S3PROXY_BINARY-"s3proxy-${S3PROXY_VERSION}"}"
CHAOS_HTTP_PROXY_VERSION="1.1.0"
CHAOS_HTTP_PROXY_BINARY="chaos-http-proxy-${CHAOS_HTTP_PROXY_VERSION}"
PJDFSTEST_HASH="c711b5f6b666579846afba399a998f74f60c488b"
if [ ! -f "$S3FS_CREDENTIALS_FILE" ]
then
echo "Missing credentials file: ${S3FS_CREDENTIALS_FILE}"
@ -194,6 +196,18 @@ function start_s3proxy {
# wait for Chaos HTTP Proxy to start
wait_for_port 1080
fi
if [ ! -d "pjd-pjdfstest-${PJDFSTEST_HASH:0:7}" ]; then
curl "https://api.github.com/repos/pjd/pjdfstest/tarball/${PJDFSTEST_HASH}" \
--fail --location --silent --output /tmp/pjdfstest.tar.gz
tar zxf /tmp/pjdfstest.tar.gz
rm -f /tmp/pjdfstest.tar.gz
rm -f pjdfstest
ln -s "pjd-pjdfstest-${PJDFSTEST_HASH:0:7}" pjdfstest
(cd pjdfstest && autoreconf -ifs && ./configure && make)
fi
}
function stop_s3proxy {

View File

@ -2573,6 +2573,43 @@ function test_statvfs() {
fi
}
function test_pjdfstest() {
# TODO: explain exclusions
# fails with -o use_cache: ../../pjdfstest/tests/rmdir/01.t
prove -rv \
../../pjdfstest/tests/chflags/*.t \
../../pjdfstest/tests/chmod/0[4689].t \
../../pjdfstest/tests/chmod/10.t \
../../pjdfstest/tests/chown/0[4689].t \
../../pjdfstest/tests/chown/10.t \
../../pjdfstest/tests/ftruncate/0[147-9].t \
../../pjdfstest/tests/ftruncate/1[0134].t \
../../pjdfstest/tests/granular/*.t \
../../pjdfstest/tests/link/*.t \
../../pjdfstest/tests/mkdir/0[347-9].t \
../../pjdfstest/tests/mkdir/1[12]*.t \
../../pjdfstest/tests/mkfifo/0[3478].t \
../../pjdfstest/tests/mkfifo/1*.t \
../../pjdfstest/tests/mknod/0[479].t \
../../pjdfstest/tests/mknod/10.t \
../../pjdfstest/tests/open/0[49].t \
../../pjdfstest/tests/open/1*.t \
../../pjdfstest/tests/open/2[0-134].t \
../../pjdfstest/tests/posix_fallocate/*.t \
../../pjdfstest/tests/rename/0[2-36-8].t \
../../pjdfstest/tests/rename/1[15-9].t \
../../pjdfstest/tests/rename/22.t \
../../pjdfstest/tests/rmdir/0[3-59].t \
../../pjdfstest/tests/rmdir/1[02-5].t \
../../pjdfstest/tests/symlink/0[13479].t \
../../pjdfstest/tests/symlink/1*.t \
../../pjdfstest/tests/truncate/0[147-9].t \
../../pjdfstest/tests/truncate/1[0134].t \
../../pjdfstest/tests/unlink/0[47-8].t \
../../pjdfstest/tests/unlink/1[02-4].t \
../../pjdfstest/tests/utimensat/0[1-58-9].t
}
function add_all_tests {
if s3fs_args | grep -q use_cache; then
add_tests test_cache_file_stat
@ -2677,6 +2714,8 @@ function add_all_tests {
# add_tests test_chown_mountpoint
add_tests test_time_mountpoint
add_tests test_statvfs
add_tests test_pjdfstest
}
init_suite