diff --git a/.gitignore b/.gitignore
index 5f2ce9bf39d3f4369734360f98a8e770780ca767..6abaaa4477f582943725f6ca334bc78c8aeb5d83 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,4 +1,5 @@
 annotation/minerva-big/
+builds/
 debian/src/
 debian/minerva*
 debian/src/*.sql
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 8383e8cfda0bb5b78d4d2bb0f6d9be483906fbea..87436b0f650542ba18cf46fe258c049288532c47 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -12,6 +12,20 @@ test_frontend:
     - npm install  
     - npm test
 
+test_backend:
+  variables:
+    POSTGRES_DB: map_viewer
+    POSTGRES_USER: map_viewer
+    POSTGRES_PASSWORD: 123qweasdzxc
+  image: debian
+  services:
+    - postgres:latest
+  stage: test
+  script:
+    - sudo apt-get update
+    - sudo apt-get install -y openjdk-8-jdk maven
+    - mvn test
+
 build_war:
   image: debian
   stage: build