Add tmt based test cases
This commit is contained in:
parent
aac0bbe0ca
commit
8d9864494a
1
.fmf/version
Normal file
1
.fmf/version
Normal file
@ -0,0 +1 @@
|
|||||||
|
1
|
10
plans/basic.fmf
Normal file
10
plans/basic.fmf
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
summary: Basic smoke test
|
||||||
|
discover:
|
||||||
|
how: fmf
|
||||||
|
prepare:
|
||||||
|
name: tmt
|
||||||
|
how: install
|
||||||
|
package:
|
||||||
|
- fonts-rpm-macros
|
||||||
|
execute:
|
||||||
|
how: tmt
|
3
tests/basic/main.fmf
Normal file
3
tests/basic/main.fmf
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
summary: Basic test
|
||||||
|
test: ./test.sh
|
||||||
|
framework: beakerlib
|
23
tests/basic/test.sh
Executable file
23
tests/basic/test.sh
Executable file
@ -0,0 +1,23 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||||
|
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||||
|
|
||||||
|
rlJournalStart
|
||||||
|
rlPhaseStartSetup
|
||||||
|
rlRun "tmp=\$(mktemp -d)" 0 "Create tmp directory"
|
||||||
|
rlRun "pushd $tmp"
|
||||||
|
rlRun "set -o pipefail"
|
||||||
|
rlPhaseEnd
|
||||||
|
|
||||||
|
rlPhaseStartTest
|
||||||
|
rlRun "fc-weight --help | tee output" 0 "Check help message for fc-weight"
|
||||||
|
rlAssertGrep "fontconfig weight" "output"
|
||||||
|
rlRun "gen-fontconf --help | tee output" 0 "Check help message for gen-fontconf"
|
||||||
|
rlAssertGrep "fontconfig syntax" "output"
|
||||||
|
rlPhaseEnd
|
||||||
|
|
||||||
|
rlPhaseStartCleanup
|
||||||
|
rlRun "popd"
|
||||||
|
rlRun "rm -r $tmp" 0 "Remove tmp directory"
|
||||||
|
rlPhaseEnd
|
||||||
|
rlJournalEnd
|
Loading…
Reference in New Issue
Block a user