Skip to content
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
4 changes: 3 additions & 1 deletion docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,9 @@ ENV PATH=/venv/bin:/usr/local/bin/:/usr/bin:/bin \
PGSSLCERT="/tmp/postgresql.crt" \
UV_PROJECT_ENVIRONMENT=/venv \
VIRTUAL_ENV=/venv \
UWSGI_PROCESSES=4
UWSGI_PROCESSES=4 \
MEDIA_ROOT="${MEDIA_ROOT:-/var/run/app/media}" \
STATIC_ROOT="${STATIC_ROOT:-/var/run/app/static}"

RUN <<EOF cat> /RELEASE
{"version": "$VERSION",
Expand Down
2 changes: 0 additions & 2 deletions docker/bin/docker-entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
#!/bin/sh -e


export MEDIA_ROOT="${MEDIA_ROOT:-/var/run/app/media}"
export STATIC_ROOT="${STATIC_ROOT:-/var/run/app/static}"
export UWSGI_PROCESSES="${UWSGI_PROCESSES:-"4"}"
export DJANGO_SETTINGS_MODULE="country_workspace.config.settings"
mkdir -p "${MEDIA_ROOT}" "${STATIC_ROOT}" || echo "Cannot create dirs ${MEDIA_ROOT} ${STATIC_ROOT}"
Expand Down
4 changes: 3 additions & 1 deletion tests/contrib/aurora/test_aurora_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import pytest
import requests
import responses
from constance.test import override_config

from country_workspace.contrib.aurora.client import AuroraClient
from country_workspace.exceptions import RemoteError
Expand All @@ -23,14 +24,15 @@
("json_decode", 200, "invalid json", lambda url: f"Wrong JSON response fetching {url}"),
],
)
@override_config(AURORA_API_URL="https://hope-dummy.org/api/rest", AURORA_API_TOKEN="dummy_token")
def test_client_exceptions(
mocked_responses: responses.RequestsMock,
error_case: str,
status_code: int,
body: dict | str,
expected_error: Callable[[str], str],
) -> None:
client = AuroraClient(token="dummy")
client = AuroraClient()
path = "dummy_path"
url = client._get_url(path)

Expand Down
1 change: 0 additions & 1 deletion tests/contrib/hope/test_hope_client.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# tests/test_hope_client.py
import re
from collections.abc import Callable
from unittest.mock import Mock
Expand Down
Loading