From 6b086ca1a90175d5d98b05b1009b599bcebfe174 Mon Sep 17 00:00:00 2001 From: Max Regan Date: Sat, 27 Nov 2021 22:01:47 -0500 Subject: [PATCH] Use correct Docker image per Pyhon version --- .gitlab-ci.yml | 34 ++++++++++++++++++++++++++++++---- setup.cfg | 2 +- 2 files changed, 31 insertions(+), 5 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 234f4ff..0f8c3bf 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,5 +1,3 @@ -image: python:latest - # Change pip's cache directory to be inside the project directory since we can # only cache local items. variables: @@ -15,6 +13,10 @@ cache: - .cache/pip - venv/ +stages: + - lint + - test + before_script: - python -V - pip install virtualenv @@ -22,11 +24,35 @@ before_script: - source venv/bin/activate lint: + stage: lint script: - pip3 install black - black --check src/ -test: +python-37: + stage: test + image: python:3.7 script: - pip3 install tox - - tox + - tox -e py37 + +python-38: + stage: test + image: python:3.8 + script: + - pip3 install tox + - tox -e py38 + +python-39: + stage: test + image: python:3.9 + script: + - pip3 install tox + - tox -e py39 + +python-310: + stage: test + image: python:3.10 + script: + - pip3 install tox + - tox -e py310 diff --git a/setup.cfg b/setup.cfg index 2a31423..aa2f8c5 100644 --- a/setup.cfg +++ b/setup.cfg @@ -28,7 +28,7 @@ console_scripts = gbasm = gbasm.gbasm:main [tox:tox] -envlist = py3{7,8,9} +envlist = py3{7,8,9,10} [testenv] deps = pytest