Add simple smoke test

Build and execute a minimal program using the libreport library
This commit is contained in:
Michal Fabik 2021-03-04 14:48:55 +01:00
parent dd2a474758
commit 9785cc8667
4 changed files with 15 additions and 0 deletions

1
.fmf/version Normal file
View File

@ -0,0 +1 @@
1

View File

@ -7,6 +7,7 @@ rules:
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.rpmdeplint.functional}
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.rpminspect.static-analysis}
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.installability.functional}
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional}
--- !Policy
product_versions:
@ -17,4 +18,5 @@ rules:
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.rpmdeplint.functional}
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.rpminspect.static-analysis}
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.installability.functional}
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional}

7
tests/smoke.fmf Normal file
View File

@ -0,0 +1,7 @@
summary: Basic smoke test for libreport
require: gcc
execute:
script: |
test/smoke.sh
report-cli --version

5
tests/smoke.sh Executable file
View File

@ -0,0 +1,5 @@
#!/usr/bin/bash
echo "int main(){libreport_init();}" | gcc -x c -lreport -Wno-implicit-function-declaration -
./a.out
rm -f a.out