diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 5b860b6ffe322bdb1bb6a7343fbd3c3def0a950d..ecda13117a10cb2eb9789ea6d1922e138f4c08dc 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -10,12 +10,12 @@ before_script:
 test_matlab:
   stage: test
   script:
-    - make check-matlab MATLAB=/usr/local/MATLAB/$MATLAB_VERSION/bin/matlab
+    - make check-matlab MATLAB=/opt/MATLAB/$MATLAB_VERSION/bin/matlab
 
 test_old_matlab:
   stage: test
   script:
-    - make check-matlab MATLAB=/usr/local/MATLAB/$OLD_MATLAB_VERSION/bin/matlab
+    - make check-matlab MATLAB=/opt/MATLAB/$OLD_MATLAB_VERSION/bin/matlab
 
 test_octave:
   stage: test