Adding tests
/CoreOS/vim/Regression/bz1083924-Include-c-11-syntax-highlighting-in-vim /CoreOS/vim/Regression/bz1204179-missing-bin-vi-breaks-visudo-sudoedit-crontab /CoreOS/vim/Regression/bz1383902-CPU-spike-on-ssh /CoreOS/vim/Regression/bz1490927-vim-dumps-core-when-system-reboots /CoreOS/vim/Regression/bz1576470-Suggest-correct-packages-to-get-embedded /CoreOS/vim/Regression/bz1602807-vim-X11-doesn-t-provide-the-gui /CoreOS/vim/Regression/bz1676339-Vim-runs-out-of-memory-during-a-find-and-replace /CoreOS/vim/Regression/bz1686822-Add-Provides-bundled-libvterm /CoreOS/vim/Regression/bz1743070-manpage-of-vim-is-garbled-in-Japanese-locale /CoreOS/vim/Regression/bz241308-use-augroup-for-rh-autocmds /CoreOS/vim/Regression/bz429208-maxmemtot-memory-calculation /CoreOS/vim/Regression/bz473977-vim-incorrectly-linked-to-libtermcap /CoreOS/vim/Regression/bz505344-netrw-plugin-delete-command-broken /CoreOS/vim/Regression/bz506442-Add-Vim-to-Applications-Accessories-menu /CoreOS/vim/Regression/bz572157-vim-in-ex-mode-incorrectly-gives-an-eol-error /CoreOS/vim/Regression/bz591578-netrw-vim-prints-additional-chars /CoreOS/vim/Regression/bz634902-rpm-spec-template-is-out-of-date /CoreOS/vim/Regression/bz652610-netrw-plugin-and-parent-directory /CoreOS/vim/Regression/bz681108-vim-crashes-while-doing-completion /CoreOS/vim/Regression/bz820331-Vim-syntax-file-for-sshdconfig-is-missing-newer /CoreOS/vim/Regression/docs /CoreOS/vim/Sanity/upstream-scripttests
This commit is contained in:
parent
dab2578f46
commit
f6ea11c9ee
54 changed files with 2183 additions and 19 deletions
29
Regression/docs/main.fmf
Normal file
29
Regression/docs/main.fmf
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
summary: Test for man pages bugs
|
||||
description: |+
|
||||
Bug summary: Conflicting manpages rvi.1.gz and vi.1.gz during update
|
||||
Bugzilla link: https://bugzilla.redhat.com/show_bug.cgi?id=1599660
|
||||
|
||||
Purpose of this file is to collect different bugs for man pages as proposed in
|
||||
https://wiki.test.redhat.com/BaseOs/BestPractices/TestsForManPages
|
||||
* "name of the test where one phase is one man page bug might be like this: /CoreOS/<component>/Sanity || Regression/docs "
|
||||
|
||||
contact: fhrdina@redhat.com
|
||||
component:
|
||||
- vim
|
||||
test: ./runtest.sh
|
||||
framework: beakerlib
|
||||
recommend:
|
||||
- vim-minimal
|
||||
- vim-common
|
||||
duration: 5m
|
||||
enabled: true
|
||||
link:
|
||||
- relates: https://bugzilla.redhat.com/show_bug.cgi?id=1599660
|
||||
adjust:
|
||||
- enabled: false
|
||||
when: distro < rhel-6
|
||||
continue: false
|
||||
extra-nitrate: TC#0575733
|
||||
extra-summary: /CoreOS/vim/Regression/docs
|
||||
extra-task: /CoreOS/vim/Regression/docs
|
||||
id: be3cbe71-027a-43a0-af60-2c91fee4ab5e
|
||||
102
Regression/docs/runtest.sh
Executable file
102
Regression/docs/runtest.sh
Executable file
|
|
@ -0,0 +1,102 @@
|
|||
#!/bin/bash
|
||||
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# runtest.sh of /CoreOS/vim/Regression/docs
|
||||
# Description: Test for man pages bugs:
|
||||
# BZ#1599660 (Conflicting manpages rvi.1.gz and vi.1.gz during)
|
||||
#
|
||||
# Author: Patrik Mosko <pmosko@redhat.com>
|
||||
#
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# Copyright (c) 2018 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
|
||||
|
||||
PACKAGES="vim-common vim-minimal"
|
||||
|
||||
rlJournalStart
|
||||
rlPhaseStartSetup
|
||||
rlRun "TmpDir=\$(mktemp -d)" 0 "Creating tmp directory"
|
||||
rlRun "pushd $TmpDir"
|
||||
rlAssertRpm --all
|
||||
rlPhaseEnd
|
||||
|
||||
############################################################
|
||||
# BZ#1599660
|
||||
############################################################
|
||||
rlPhaseStartTest "Test conflicting vim-{common,minimal} man pages"
|
||||
VIMmin_ver=(`rpm -q vim-minimal | rev | sed -r 's;^[^.]*.[^.]*.([^-]*-[^-]*)-.*$;\1;' | rev | tr '.-' ' '`)
|
||||
VIMcom_ver=(`rpm -q vim-common | rev | sed -r 's;^[^.]*.[^.]*.([^-]*-[^-]*)-.*$;\1;' | rev | tr '.-' ' '`)
|
||||
VIMcom_conf_ver=(`rpm -q --conflicts vim-minimal | grep vim-common | awk '{print $3}' | tr '.-' ' '`)
|
||||
VIMmin_conf_ver=(`rpm -q --conflicts vim-common | grep vim-minimal | awk '{print $3}' | tr '.-' ' '`)
|
||||
|
||||
# check only man-page files, could be changed to all files
|
||||
rpm -ql vim-minimal | grep /man/ > VimMinRpmFiles
|
||||
rpm -ql vim-common | grep /man/ > VimComRpmFiles
|
||||
rlAssertExists VimMinRpmFiles
|
||||
rlAssertExists VimComRpmFiles
|
||||
rlAssertNotGrep VimMinRpmFiles VimComRpmFiles -w -f
|
||||
|
||||
#check version of actual vim-minimal with the one[s] that vim-common is conflicting with
|
||||
higher=0
|
||||
for v in "${!VIMmin_conf_ver[@]}"; do
|
||||
(( ${VIMmin_ver[$v]} >= ${VIMmin_conf_ver[$v]} )) && [[ $higher == 0 ]] || break
|
||||
#at least one part of the version should be higher than the same part in the other vim's rpm's
|
||||
(( ${VIMmin_ver[$v]} > ${VIMmin_conf_ver[$v]} )) && (( higher++ ))
|
||||
done
|
||||
if [ ${VIMmin_conf_ver[@]} -eq 0 ]; then
|
||||
rlPass "vim-common doesn't conflicts with vim-minimal"
|
||||
elif [ $higher -ge 0 ]; then
|
||||
rlPass "Actual version of vim-minimal is not conflicting with vim-common"
|
||||
else
|
||||
rlFail "Actual version of vim-minimal may conflicts with vim-common"
|
||||
fi
|
||||
|
||||
#check version of actual vim-common with the one[s] that vim-minimal is conflicting with
|
||||
higher=0
|
||||
for v in "${!VIMcom_conf_ver[@]}"; do
|
||||
(( ${VIMcom_ver[$v]} >= ${VIMcom_conf_ver[$v]} )) && [[ $higher == 0 ]] || break
|
||||
#at least one part of the version should be higher than the same part in the other vim's rpm's
|
||||
(( ${VIMcom_ver[$v]} > ${VIMcom_conf_ver[$v]} )) && (( higher++ ))
|
||||
done
|
||||
if [ ${VIMcom_conf_ver[@]} -eq 0 ]; then
|
||||
rlPass "vim-common doesn't conflicts with vim-minimal"
|
||||
elif [ $higher -ge 0 ]; then
|
||||
rlPass "Actual version of vim-common is not conflicting with vim-minimal"
|
||||
else
|
||||
rlFail "Actual version of vim-common may conflicts with vim-minimal"
|
||||
fi
|
||||
rlPhaseEnd
|
||||
|
||||
# BZ#???????
|
||||
# As RECOMMENDED in Best QA Practices, each man page fix that needs test case
|
||||
# should be inserted here as independent Test Phase
|
||||
#rlPhaseStartTest
|
||||
# rlRun ""
|
||||
#rlPhaseEnd
|
||||
|
||||
rlPhaseStartCleanup
|
||||
rlRun "popd"
|
||||
rlRun "rm -r $TmpDir" 0 "Removing tmp directory"
|
||||
rlPhaseEnd
|
||||
rlJournalPrintText
|
||||
rlJournalEnd
|
||||
Loading…
Add table
Add a link
Reference in a new issue