From 8cd7a8993951b9fb7a182986bb4a2e176b419769 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Victor=20L=C3=B6fgren?= <victor.l0fgr3n@gmail.com>
Date: Tue, 16 Feb 2021 11:47:42 +0100
Subject: [PATCH] #3: Add server test pipline

---
 .gitignore     |  3 ++-
 .gitlab-ci.yml | 20 ++++++++++++++++++++
 2 files changed, 22 insertions(+), 1 deletion(-)
 create mode 100644 .gitlab-ci.yml

diff --git a/.gitignore b/.gitignore
index 0d14ca4d..9f28e5cb 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,4 +1,5 @@
 __pycache__
 *.db
 */env
-*.coverage
\ No newline at end of file
+*.coverage
+.pytest_cache
\ No newline at end of file
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
new file mode 100644
index 00000000..82bed410
--- /dev/null
+++ b/.gitlab-ci.yml
@@ -0,0 +1,20 @@
+image: python
+
+stages:
+  - install
+  - test
+
+install:
+  stage: install
+  script:
+    - pip install virtualenv
+    - cd server
+    - python -m venv env
+    - ./env/Scripts/activate
+    - pip install -r requirements.txt
+
+test:
+  stage: test
+  script:
+    - cd server
+    - pytest --cov app test/
-- 
GitLab