fix: Passing tests

This commit is contained in:
Andrejus
2021-06-28 17:30:47 +01:00
parent 4625f0f906
commit b6b9d38b5b
3 changed files with 9 additions and 7 deletions

View File

@@ -15,14 +15,17 @@ RUN adduser "test-user" sudo
RUN echo "test-user ALL=(ALL) NOPASSWD: ALL" \ RUN echo "test-user ALL=(ALL) NOPASSWD: ALL" \
>>/etc/sudoers >>/etc/sudoers
# #
# source: Base image with source copied over # source: Base image with source copied over
# #
FROM debian-base AS source FROM debian-base AS source
ARG DOTFILES_DIR="/home/test-user/.dotfiles" ARG DOTFILES_DIR="/home/test-user/.dotfiles"
ADD --chown="test-user" . "$DOTFILES_DIR" RUN mkdir ${DOTFILES_DIR}
RUN chown test-user ${DOTFILES_DIR}
ADD --chown="test-user" files "$DOTFILES_DIR/files"
ADD --chown="test-user" scripts "$DOTFILES_DIR/scripts"
WORKDIR "$DOTFILES_DIR" WORKDIR "$DOTFILES_DIR"
@@ -42,5 +45,6 @@ RUN ./scripts/install.sh
# #
FROM install AS test FROM install AS test
ADD --chown="test-user" tests "$DOTFILES_DIR/tests"
WORKDIR "${DOTFILES_DIR}/tests" WORKDIR "${DOTFILES_DIR}/tests"
ENTRYPOINT [ "${DOTFILES_DIR}/tests/run.sh" ] ENTRYPOINT [ "./run.sh" ]

View File

@@ -1,4 +1,5 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
bash -l -c "poetry install && poetry run pytest" # pyenv install --skip-existing && pyenv shell
poetry install && poetry run pytest

View File

@@ -63,7 +63,6 @@ binaries: List[str] = [
"poetry", "poetry",
# langauge: js # langauge: js
"nvm",
"node", "node",
"npm", "npm",
"yarn", "yarn",
@@ -71,8 +70,6 @@ binaries: List[str] = [
# language: java # language: java
"java", "java",
# langauge: ruby
"ruby"
] ]