From 45167512cbf100c95249c823bf99342a4ed1169c Mon Sep 17 00:00:00 2001
From: razzanYoni <13521087@mahasiswa.itb.ac.id>
Date: Thu, 2 May 2024 20:01:08 +0700
Subject: [PATCH] add ci

---
 .coveragerc    |  6 ++++++
 .gitlab-ci.yml | 13 +++++++++++++
 2 files changed, 19 insertions(+)
 create mode 100644 .coveragerc
 create mode 100644 .gitlab-ci.yml

diff --git a/.coveragerc b/.coveragerc
new file mode 100644
index 0000000..ef9227f
--- /dev/null
+++ b/.coveragerc
@@ -0,0 +1,6 @@
+[html]
+directory = coverage
+
+[report]
+exclude_lines =
+    if __name__ == .__main__.:
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
new file mode 100644
index 0000000..d351915
--- /dev/null
+++ b/.gitlab-ci.yml
@@ -0,0 +1,13 @@
+stages:
+  - test
+
+unit-test:
+  stage: test
+  image: python:3.12
+  script:
+      - pip install -r requirements.txt
+      - pytest --cov-report=html --cov=src
+  artifacts:
+    paths:
+        - coverage
+    expire_in: 30days
\ No newline at end of file
-- 
GitLab