We will use upstream test
This commit is contained in:
parent
41058ecd86
commit
63dcea5085
2 changed files with 0 additions and 88 deletions
|
|
@ -1,18 +0,0 @@
|
|||
summary: The test tests cups-browsed without any remote printer. This should help
|
||||
us test cups-browsed on fedora without our printers.
|
||||
description: ''
|
||||
contact: Petr Dancak <pdancak@redhat.com>
|
||||
component:
|
||||
- cups-browsed
|
||||
test: ./runtest.sh
|
||||
framework: beakerlib
|
||||
recommend:
|
||||
- cups-browsed
|
||||
- cups
|
||||
- cups-printerapp
|
||||
- avahi
|
||||
duration: 10m
|
||||
extra-summary: /CoreOS/cups-browsed/Sanity/Cups_browsed_with_local_printer
|
||||
extra-task: /CoreOS/cups-browsed/Sanity/Cups_browsed_with_local_printer
|
||||
extra-nitrate: TC#0615129
|
||||
id: 59f96529-453e-4654-979e-e8b492949f5d
|
||||
|
|
@ -1,70 +0,0 @@
|
|||
#!/bin/bash
|
||||
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# runtest.sh of /CoreOS/cups-browsed/Sanity/Cups_browsed_with_local_printer
|
||||
# Description: The test tests cups-browsed without any remote printer. This should help us test cups-browsed on fedora without our printers.
|
||||
# Author: Petr Dancak <pdancak@redhat.com>
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# Copyright (c) 2023 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="cups-browsed"
|
||||
PACKAGE2="cups-printerapp"
|
||||
PACKAGE3="avahi"
|
||||
PACKAGE4="cups"
|
||||
PRINTER="test$RANDOM"
|
||||
|
||||
rlJournalStart
|
||||
rlPhaseStartSetup
|
||||
rlAssertRpm $PACKAGE
|
||||
rlAssertRpm $PACKAGE2
|
||||
rlAssertRpm $PACKAGE3
|
||||
rlAssertRpm $PACKAGE4
|
||||
rlRun "TmpDir=\$(mktemp -d)" 0 "Creating tmp directory"
|
||||
rlRun "pushd $TmpDir"
|
||||
rlServiceStop "cups-browsed"
|
||||
rlServiceStart "cups" "avahi-daemon"
|
||||
rlLog "Installing local printer test with mDNS record"
|
||||
ippeveprinter -D "$TmpDir/test_output" -c /usr/bin/cat "$PRINTER" &
|
||||
sleep 20
|
||||
rlPhaseEnd
|
||||
|
||||
rlPhaseStartTest
|
||||
rlRun "lpstat -a | grep $PRINTER" 1 "$PRINTER shouldn't be found when cups-browsed is not active"
|
||||
rlRun "systemctl start cups-browsed" 0 "Start cups-browsed to find $PRINTER"
|
||||
sleep 20
|
||||
rlRun "lpstat -a | grep $PRINTER" 0 "Lpstat should find $PRINTER"
|
||||
rlRun "lp -d $PRINTER /etc/fstab"
|
||||
sleep 120
|
||||
rlAssertExists "$TmpDir/test_output"
|
||||
rlPhaseEnd
|
||||
|
||||
rlPhaseStartCleanup
|
||||
rlRun "kill -9 `pidof ippeveprinter`" "0-199"
|
||||
rlServiceRestore "avahi-daemon" "cups" "cups-browsed"
|
||||
rlRun "popd"
|
||||
rlRun "rm -r $TmpDir" 0 "Removing tmp directory"
|
||||
rlRun "rm -rf /var/cache/cups/*"
|
||||
rlPhaseEnd
|
||||
rlJournalPrintText
|
||||
rlJournalEnd
|
||||
Loading…
Add table
Add a link
Reference in a new issue