From 7bd0592ea128979fd9463a77e5e0e4fe6f9a43b6 Mon Sep 17 00:00:00 2001
From: Dantali0n <info@dantalion.nl>
Date: Thu, 6 Jul 2023 18:06:36 +0200
Subject: [PATCH] Ensure unit test script does not get overwritten

---
 .gitlab-ci.yml                               | 8 ++++++++
 {{cookiecutter.project_slug}}/.gitlab-ci.yml | 2 +-
 2 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 2ce603d..4da506a 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -15,6 +15,14 @@ default:
     - cd my_awesome_app
     - git init
 
+# Override unit test before script
+.run_unit_test_version_base:
+  before_script:
+    - !reference [default, before_script]
+    - python --version # For debugging
+    - python -m pip install --upgrade pip
+    - pip install --upgrade tox twine
+
 # Override artifact directories
 run_unit_tests_coverage:
   artifacts:
diff --git a/{{cookiecutter.project_slug}}/.gitlab-ci.yml b/{{cookiecutter.project_slug}}/.gitlab-ci.yml
index ead4cc5..3bd2346 100644
--- a/{{cookiecutter.project_slug}}/.gitlab-ci.yml
+++ b/{{cookiecutter.project_slug}}/.gitlab-ci.yml
@@ -68,7 +68,7 @@ run_unit_tests:
     - tox -e py3${PY_VERSION}
   parallel:
     matrix: # use the matrix for testing
-      - PY_VERSION: [7, 8, 9, 10]
+      - PY_VERSION: [8, 9, 10, 11]
 
 # Run code coverage on the base image thus also performing unit tests
 run_unit_tests_coverage:
-- 
GitLab