Skip to content

Commit

Permalink
fix docker dev unit tests setup
Browse files Browse the repository at this point in the history
  • Loading branch information
MvWouden committed Oct 17, 2023
1 parent e1b871c commit 9a03790
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions Dockerfile-dev
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,20 @@ ENV PATH $POETRY_HOME/bin:$PATH

WORKDIR /app

COPY MPSSRC MPSSRC
COPY tests tests
RUN touch README.md # requirement for some tools

# Install dependencies into a virtual environment
# hadolint global ignore=SC1091
COPY pyproject.toml poetry.lock ./
RUN python3 -m venv --copies /app/venv; \
source venv/bin/activate; \
poetry install --no-root --no-interaction --with dev
poetry install --no-interaction --with dev
ENV PATH /app/venv/bin:$PATH

COPY MPSSRC src
COPY tests tests

ENV ENV dev
ENV APP_ENV $ENV

CMD ["poetry", "run", "pytest", "--cov-report", "term-missing", "--cov=src", "--typeguard-packages=src"]
CMD ["poetry", "run", "pytest", "--cov-report", "term-missing", "--cov=MPSSRC", "--typeguard-packages=MPSSRC"]

0 comments on commit 9a03790

Please sign in to comment.