Skip to content

Commit e222769

Browse files
committed
TestKit Docker: install tools for all python versions
1 parent a379268 commit e222769

File tree

1 file changed

+11
-10
lines changed

1 file changed

+11
-10
lines changed

testkit/Dockerfile

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -39,18 +39,19 @@ RUN git clone https://github.com/pyenv/pyenv.git .pyenv
3939
ENV PYENV_ROOT /.pyenv
4040
ENV PATH $PYENV_ROOT/shims:$PYENV_ROOT/bin:$PATH
4141

42-
# Set minimum supported Python version
43-
RUN pyenv install 3.6:latest
44-
RUN pyenv install 3.7:latest
45-
RUN pyenv install 3.8:latest
46-
RUN pyenv install 3.9:latest
42+
# Setup python version
43+
ENV PYTHON_VERSIONS 3.7 3.8 3.9 3.10
44+
45+
RUN for version in $PYTHON_VERSIONS; do \
46+
pyenv install $version:latest; \
47+
done
4748
RUN pyenv rehash
4849
RUN pyenv global $(pyenv versions --bare --skip-aliases)
4950

5051
# Install Latest pip and setuptools for each environment
5152
# https://pip.pypa.io/en/stable/news/
52-
RUN python -m pip install --upgrade pip
53-
RUN python -m pip install --upgrade setuptools
54-
55-
# Install Python Testing Tools
56-
RUN python -m pip install coverage tox
53+
RUN for version in $PYTHON_VERSIONS; do \
54+
python${version} -m pip install -U pip && \
55+
python${version} -m pip install -U setuptools && \
56+
python${version} -m pip install -U coverage tox tox-factor; \
57+
done

0 commit comments

Comments
 (0)