From f417796d5da3836f1f2b188c19e88563bb0a0a59 Mon Sep 17 00:00:00 2001
From: fspreck <f.spreckelsen@indiscale.com>
Date: Thu, 27 Oct 2022 18:06:43 +0200
Subject: [PATCH] WIP: Add Python 3.9 and 3.10 to pipeline

---
 .gitlab-ci.yml | 26 ++++++++++++++++++++++++--
 1 file changed, 24 insertions(+), 2 deletions(-)

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index f38a1ac9..fef8bc30 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -59,12 +59,34 @@ unittest_py3.8:
   stage: test
   needs: [ ]
   image: python:3.8
-  script: &python_test_script
+  script:
+    # Python3.8 has problems with tox and pip so use plain pytest here
     - touch ~/.pycaosdb.ini
     - pip install nose pytest pytest-cov python-dateutil jsonschema==4.0.1
     - pip install .
     - python -m pytest unittests
 
+unittest_py3.9:
+  tags: [ docker ]
+  stage: test
+  needs: [ ]
+  image: python:3.9
+  script: &python_test_script
+    # Python3.8 has problems with tox and pip so use plain pytest here
+    - touch ~/.pycaosdb.ini
+    - cd unittests/docker
+    - cp sources.list.local /etc/apt/
+    - mv /etc/apt/sources.list /etc/apt/sources.list.orig
+    - cat /etc/apt/sources.list.local /etc/apt/sources.list.orig > /etc/apt/sources.list
+    - apt-get update apt-get install -y tox
+
+unittest_py3.10:
+  tags: [ docker ]
+  stage: test
+  needs: [ ]
+  image: python:3.10
+  script: *python_test_script    
+
 # Trigger building of server image and integration tests
 trigger_build:
   stage: deploy
@@ -108,7 +130,7 @@ build-testenv:
 pages_prepare: &pages_prepare
   tags: [ cached-dind ]
   stage: deploy
-  needs: [ code_style, pylint, unittest_py3.8 ]
+  needs: [ code_style, pylint, unittest_py3.8, unittest_py3.9, unittest_py3.10 ]
   only:
     refs:
       - /^release-.*$/i
-- 
GitLab