From 78f431c51e63ba3d78bee237232a5640f9301f6d Mon Sep 17 00:00:00 2001
From: Benjamin Bertrand <benjamin.bertrand@ess.eu>
Date: Mon, 9 Mar 2020 16:32:53 +0100
Subject: [PATCH] Add extra badges to README and documentation

- add term coverage report to capture it in gitlab-ci
- add pipeline and coverage badges
---
 .gitlab-ci.yml |  2 +-
 README.rst     |  4 ++++
 docs/index.rst | 12 ++++++++++++
 3 files changed, 17 insertions(+), 1 deletion(-)

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index e4e27d5..0eb15e7 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -47,7 +47,7 @@ test:
   before_script:
     - pip install -r requirements-dev.txt
   script:
-    - pytest --junitxml=junit.xml --cov-report xml:coverage.xml --cov=app -v
+    - pytest --junitxml=junit.xml --cov-report=xml:coverage.xml --cov-report=term --cov=app -v
   artifacts:
     paths:
       - junit.xml
diff --git a/README.rst b/README.rst
index 4b95686..1fa3bea 100644
--- a/README.rst
+++ b/README.rst
@@ -7,6 +7,10 @@ CSEntry
 .. image:: https://sonarqube.esss.lu.se/api/project_badges/measure?project=csentry&metric=alert_status
     :target: https://sonarqube.esss.lu.se/dashboard?id=csentry
 
+.. image:: https://gitlab.esss.lu.se/ics-infrastructure/csentry/badges/master/pipeline.svg
+
+.. image:: https://gitlab.esss.lu.se/ics-infrastructure/csentry/badges/master/coverage.svg
+
 Control System Entry web server.
 
 
diff --git a/docs/index.rst b/docs/index.rst
index a6a6fac..fa97e77 100644
--- a/docs/index.rst
+++ b/docs/index.rst
@@ -6,6 +6,18 @@
 Control System Entry
 ====================
 
+.. image:: https://img.shields.io/badge/code%20style-black-000000.svg
+    :target: https://github.com/ambv/black
+
+.. image:: https://sonarqube.esss.lu.se/api/project_badges/measure?project=csentry&metric=alert_status
+    :target: https://sonarqube.esss.lu.se/dashboard?id=csentry
+
+.. image:: https://gitlab.esss.lu.se/ics-infrastructure/csentry/badges/master/pipeline.svg
+    :target: https://gitlab.esss.lu.se/ics-infrastructure/csentry
+
+.. image:: https://gitlab.esss.lu.se/ics-infrastructure/csentry/badges/master/coverage.svg
+    :target: https://gitlab.esss.lu.se/ics-infrastructure/csentry
+
 Release |version|.
 
 Control System Entry is a web application that facilitates the tracking of physical items
-- 
GitLab