diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 48647d11bd4efbaa867ba2758354e228b15a43a0..63d548ee7c2c4208a9e1178488f851b175d4e9ed 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -1,12 +1,15 @@
 image: node:6
 
+# Install node libraries
 before_script:
   - npm install
   
+# Run JEST tests
 test:
   script:
     - npm test
     
+# Publish coverage report on gitlab-pages
 pages:
   stage: deploy
   script:
@@ -18,3 +21,18 @@ pages:
     - public
   only:
   - master
+
+# Set up MySQL test-database
+services:
+  - mysql:latest
+
+# Configure test-database
+variables:
+  MYSQL_DATABASE: db
+  MYSQL_ROOT_PASSWORD: password
+  
+# Create database tables
+connect:
+  image: mysql
+  script:
+  - echo "SELECT 'OK';" | mysql --user=root --password="$MYSQL_ROOT_PASSWORD" --host=mysql "$MYSQL_DATABASE" < create_tables.sql
diff --git a/create_tables.sql b/create_tables.sql
new file mode 100644
index 0000000000000000000000000000000000000000..c56947ef83ae961933e22f8df36fad4f311ad6f8
--- /dev/null
+++ b/create_tables.sql
@@ -0,0 +1,7 @@
+CREATE TABLE`person` (
+  `id` int(11) NOT NULL,
+  `navn` varchar(256) NOT NULL,
+  `alder` int(3) DEFAULT NULL,
+  `adresse` varchar(256) NOT NULL,
+  `bilde_base64` longtext
+) ENGINE=InnoDB DEFAULT CHARSET=latin1;
\ No newline at end of file