Resolves: rhbz#1979528 Add CI tests and gating.yaml
This commit is contained in:
parent
f7aa431fee
commit
680fb4929a
|
@ -0,0 +1 @@
|
|||
1
|
|
@ -0,0 +1,6 @@
|
|||
--- !Policy
|
||||
product_versions:
|
||||
- rhel-9
|
||||
decision_context: osci_compose_gate
|
||||
rules:
|
||||
- !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional}
|
|
@ -0,0 +1,9 @@
|
|||
summary: Basic smoke test
|
||||
discover:
|
||||
how: fmf
|
||||
execute:
|
||||
how: tmt
|
||||
prepare:
|
||||
how: shell
|
||||
script:
|
||||
- dnf config-manager --enable rhel-CRB --enable rhel-buildroot
|
|
@ -0,0 +1,5 @@
|
|||
require:
|
||||
- appstream
|
||||
- emoji-picker
|
||||
test: python3 test_appstream.py -v
|
||||
framework: shell
|
|
@ -0,0 +1,46 @@
|
|||
import unittest
|
||||
import sys
|
||||
import subprocess
|
||||
|
||||
class TestAppstream(unittest.TestCase):
|
||||
|
||||
def test_dummy(self):
|
||||
self.assertEqual(True, True)
|
||||
|
||||
@unittest.expectedFailure
|
||||
def test_expected_failure(self):
|
||||
self.assertEqual(False, True)
|
||||
|
||||
def test_appstreamcli_search(self):
|
||||
cp = subprocess.run(
|
||||
['env LC_ALL=en_US.UTF-8 appstreamcli search emoji-picker'],
|
||||
encoding='UTF-8',
|
||||
text=True,
|
||||
shell=True,
|
||||
capture_output=True)
|
||||
output_lines = cp.stdout.split('\n')
|
||||
print('----------------------------------------')
|
||||
print(output_lines)
|
||||
print('----------------------------------------')
|
||||
self.assertTrue(
|
||||
'Identifier: org.freedesktop.ibus.engine.typing_booster.emoji_picker [desktop-application]'
|
||||
in output_lines)
|
||||
self.assertTrue(
|
||||
'Name: Emoji Picker'
|
||||
in output_lines)
|
||||
self.assertTrue(
|
||||
'Summary: Emoji browsing tool'
|
||||
in output_lines)
|
||||
self.assertTrue(
|
||||
'Homepage: https://mike-fabian.github.io/ibus-typing-booster/'
|
||||
in output_lines)
|
||||
self.assertTrue(
|
||||
'Icon: ibus-typing-booster.png'
|
||||
in output_lines)
|
||||
# This section not always there, better don’t test for thi
|
||||
# self.assertTrue(
|
||||
# 'Package: emoji-picker'
|
||||
# in output_lines)
|
||||
|
||||
if __name__ == "__main__":
|
||||
unittest.main()
|
Loading…
Reference in New Issue