[Spice-devel] [PATCH libcacard 44/45] Set up the CI in gitlab including coverage reports

Jakub Jelen jjelen at redhat.com
Tue Jul 31 14:50:38 UTC 2018


Signed-off-by: Jakub Jelen <jjelen at redhat.com>
Reviewed-by: Robert Relyea <rrelyea at redhat.com>
---
 .gitlab-ci.yml | 53 ++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 53 insertions(+)
 create mode 100644 .gitlab-ci.yml

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
new file mode 100644
index 0000000..7eb7a22
--- /dev/null
+++ b/.gitlab-ci.yml
@@ -0,0 +1,53 @@
+.base: &base_job
+  artifacts:
+    expire_in: '1 week'
+    paths:
+      - test-suite.log
+      - libcacard-*-coverage
+  only:
+    - master
+
+Build:
+  <<: *base_job
+  stage: build
+  script:
+    - autoreconf -i
+    - ./configure
+    - make
+
+Check:
+  <<: *base_job
+  stage: test
+  script:
+    - autoreconf -i
+    - ./configure --enable-code-coverage
+    - bash run_tests.sh
+    - make code-coverage-capture
+    - lcov --summary libcacard-*-coverage.info
+  tags:
+    - linux
+
+Memcheck:
+  <<: *base_job
+  stage: test
+  script:
+    - autoreconf -i
+    - ./configure
+    - sed -e "s/make check/make memcheck-local/" -i run_tests.sh
+    - bash run_tests.sh
+  tags:
+    - linux
+  allow_failure: true
+
+pages:
+  stage: deploy
+  dependencies:
+    - Check
+  script:
+    - mv *-coverage/ public/
+  artifacts:
+    paths:
+      - public
+    expire_in: 30 days
+  only:
+    - master
-- 
2.17.1



More information about the Spice-devel mailing list