diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index d23737440e28ff2eb51599c354c834e75cfade61..37da8e767eaaccf8e7814f1adf1dc3a1009b8810 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -14,6 +14,7 @@ test:
     - npm test
   except:
     refs:
+      - master
       - tags
     variables:
       - $GITLAB_USER_ID == $GIT_BOT_USER_ID
@@ -22,6 +23,7 @@ publish:
   stage: publish
   script:
     - npm run build
+    - npm test
     - npx semantic-release
   only:
     - master