# We use this container to set up a mock environment for testing # Doing this within a container lets us easily manage a file tree, # borg repositories, etc., without polluting the development environment. FROM docker.io/library/alpine:3.16.0 RUN apk --update add borgbackup RUN apk --update add bash RUN apk --update add postgresql RUN apk --update add coreutils # needed for full `time` functionality RUN apk --update add moreutils # needed for sponge WORKDIR /usr/src/revocatio COPY generate_file_tests.sh . COPY revocatio-test . RUN bash generate_file_tests.sh COPY generate_borg_tests.sh . RUN bash generate_borg_tests.sh COPY generate_psql_tests.sh . COPY data/ tests/data/ RUN bash generate_psql_tests.sh ENV REVOCATIO_TEST_DIR=/usr/src/revocatio CMD ["./revocatio-test"]