From 1b6496d171cb69bbaca97bae285f7d646f5a88e6 Mon Sep 17 00:00:00 2001 From: Martin Coufal Date: Tue, 30 Jan 2024 17:22:56 +0100 Subject: [PATCH] CI Tests: add Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports test --- .../Makefile | 64 +++++++++++++++++++ .../PURPOSE | 9 +++ .../main.fmf | 24 +++++++ .../runtest.sh | 54 ++++++++++++++++ 4 files changed, 151 insertions(+) create mode 100644 tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/Makefile create mode 100644 tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/PURPOSE create mode 100644 tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/main.fmf create mode 100755 tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/runtest.sh diff --git a/tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/Makefile b/tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/Makefile new file mode 100644 index 0000000..378022c --- /dev/null +++ b/tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/Makefile @@ -0,0 +1,64 @@ +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Makefile of /tools/glibc/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports +# Description: Test for BZ#1577212 (glibc Remove stray Sun RPC exports) +# Author: Alexandra Hájková +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2019 Red Hat, 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 2 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/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +export TEST=/tools/glibc/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports +export TESTVERSION=1.0 + +BUILT_FILES= + +FILES=$(METADATA) runtest.sh Makefile PURPOSE + +.PHONY: all install download clean + +run: $(FILES) build + ./runtest.sh + +build: $(BUILT_FILES) + test -x runtest.sh || chmod a+x runtest.sh + +clean: + rm -f *~ $(BUILT_FILES) + + +include /usr/share/rhts/lib/rhts-make.include + +$(METADATA): Makefile + @echo "Owner: Alexandra Hájková " > $(METADATA) + @echo "Name: $(TEST)" >> $(METADATA) + @echo "TestVersion: $(TESTVERSION)" >> $(METADATA) + @echo "Path: $(TEST_DIR)" >> $(METADATA) + @echo "Description: Test for BZ#1577212 (glibc Remove stray Sun RPC exports)" >> $(METADATA) + @echo "Type: Regression" >> $(METADATA) + @echo "TestTime: 1h" >> $(METADATA) + @echo "RunFor: glibc" >> $(METADATA) + @echo "Requires: glibc elfutils" >> $(METADATA) + @echo "Priority: Normal" >> $(METADATA) + @echo "License: GPLv2+" >> $(METADATA) + @echo "Confidential: no" >> $(METADATA) + @echo "Destructive: no" >> $(METADATA) + @echo "Bug: 1577212" >> $(METADATA) + @echo "Releases: -RHEL4 -RHEL5 -RHEL6 -RHEL7" >> $(METADATA) + + rhts-lint $(METADATA) diff --git a/tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/PURPOSE b/tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/PURPOSE new file mode 100644 index 0000000..d77a6de --- /dev/null +++ b/tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/PURPOSE @@ -0,0 +1,9 @@ +PURPOSE of /tools/glibc/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports +Description: Test for BZ#1577212 (glibc Remove stray Sun RPC exports) +Author: Alexandra Hájková +Bug summary: glibc: Remove stray Sun RPC exports +Bugzilla link: https://bugzilla.redhat.com/show_bug.cgi?id=1577212 + +Remove stray Sun RPC exports: In this context, “remove“ means that the default symbol version (the @@ part) +is gone, and there is only a compat symbol (with a single @). We cannot remove the compat symbols for +backwards compatibility reasons. diff --git a/tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/main.fmf b/tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/main.fmf new file mode 100644 index 0000000..e251cec --- /dev/null +++ b/tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/main.fmf @@ -0,0 +1,24 @@ +summary: Test for BZ#1577212 (glibc Remove stray Sun RPC exports) +description: | + Bug summary: glibc: Remove stray Sun RPC exports + Bugzilla link: https://bugzilla.redhat.com/show_bug.cgi?id=1577212 + + Remove stray Sun RPC exports: In this context, “remove“ means that the + default symbol version (the @@ part) is gone, and there is only a compat + symbol (with a single @). We cannot remove the compat symbols for backwards + compatibility reasons. +contact: Alexandra Hájková +link: + - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1577212 +component: + - glibc +test: ./runtest.sh +framework: beakerlib +recommend: + - glibc + - elfutils +duration: 1h +extra-summary: + /tools/glibc/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports +extra-task: + /tools/glibc/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports diff --git a/tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/runtest.sh b/tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/runtest.sh new file mode 100755 index 0000000..6513c9a --- /dev/null +++ b/tests/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports/runtest.sh @@ -0,0 +1,54 @@ +#!/bin/bash +# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# runtest.sh of /tools/glibc/Regression/bz1577212-glibc-Remove-stray-Sun-RPC-exports +# Description: Test for BZ#1577212 (glibc Remove stray Sun RPC exports) +# Author: Alexandra Hájková +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# +# Copyright (c) 2019 Red Hat, 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 2 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/. +# +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +# Include Beaker environment +. /usr/share/beakerlib/beakerlib.sh || exit 1 + +PACKAGE="glibc" + +rlJournalStart + rlPhaseStartSetup + rlAssertRpm $PACKAGE + rlRun "TmpDir=\$(mktemp -d)" 0 "Creating tmp directory" + rlRun "pushd $TmpDir" + rlPhaseEnd + + rlPhaseStartTest + rlRun "eu-readelf --symbols=.dynsym /usr/lib64/libc.so.6 > log" + rlAssertNotGrep "svcauthdes_stats@@" log + rlAssertNotGrep "svc_pollfd@@" log + rlAssertNotGrep "rpc_createerr@@" log + rlAssertNotGrep "svc_fdset@@" log + rlAssertNotGrep "svc_max_pollfd@@" log + rlPhaseEnd + + rlPhaseStartCleanup + rlRun "popd" + rlRun "rm -r $TmpDir" 0 "Removing tmp directory" + rlPhaseEnd +rlJournalPrintText +rlJournalEnd