Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't just mount spec folder, but complete app folder for tests #648

Merged
merged 3 commits into from
Jun 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion docker/test/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ RUN apt update && \
RUN sed -i '/disable ghostscript format types/,+6d' /etc/ImageMagick-6/policy.xml

WORKDIR /usr/src/app
ENTRYPOINT ["./entrypoint.sh"]

COPY ./Gemfile ./Gemfile.lock ./yarn.lock ./package.json /usr/src/app/
RUN bundle install
Expand All @@ -66,7 +67,7 @@ RUN yarn install --production=false
COPY --from=build-pdfcomprezzor /go/src/pdfcomprezzor.wasm /go/src/wasm_exec.js /usr/src/app/public/pdfcomprezzor/
COPY --from=build-pdfcomprezzor /go/src/pdfcomprezzor.wasm /go/src/wasm_exec.js /

COPY . /usr/src/app/
COPY . /usr/src/app
COPY ./docker/production/docker.env ./docker-dummy.env

RUN set -o allexport && . ./docker-dummy.env && set +o allexport && \
Expand Down
10 changes: 3 additions & 7 deletions docker/test/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,6 @@ services:
context: ./../..
dockerfile: docker/test/Dockerfile
image: mampf:tests
# TODO: Use this
# entrypoint: /usr/src/app/docker/test/run_tests.sh
entrypoint: /usr/src/app/entrypoint.sh
environment:
RAILS_ENV: test
TEST_DATABASE_ADAPTER: postgresql
Expand Down Expand Up @@ -68,10 +65,9 @@ services:
SPROCKETS_CACHE: /cache
BLOG: https://mampf.blog
volumes:
- type: bind
source: ../../spec/
target: /usr/src/app/spec/
- ../../coverage:/usr/src/app/coverage
- ../../:/usr/src/app/
- ../../coverage:/usr/src/app/coverage/
- "/usr/src/app/public/"
fosterfarrell9 marked this conversation as resolved.
Show resolved Hide resolved
depends_on:
- db
- solr
Expand Down