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

Remove in memory wallet #3311

Merged
merged 7 commits into from
Nov 5, 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
1 change: 1 addition & 0 deletions .devcontainer/post-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,5 @@ markers = [
"postgres: Tests relating to the postgres storage plugin for Indy"]
junit_family = "xunit1"
asyncio_mode = auto
asyncio_default_fixture_loop_scope = module
EOF
2 changes: 1 addition & 1 deletion .github/actions/run-unit-tests/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ runs:
- name: Tests
shell: bash
run: |
poetry run pytest --cov=acapy_agent --cov-report term-missing --cov-report xml --ignore-glob=/tests/* --ignore-glob=demo/* --ignore-glob=docker/* --ignore-glob=docs/* --ignore-glob=scripts/* --ignore-glob=scenarios/* 2>&1 | tee pytest.log
poetry run pytest -n auto --cov=acapy_agent --cov-report term-missing --cov-report xml --ignore-glob=/tests/* --ignore-glob=demo/* --ignore-glob=docker/* --ignore-glob=docs/* --ignore-glob=scripts/* --ignore-glob=scenarios/* 2>&1 | tee pytest.log
PYTEST_EXIT_CODE=${PIPESTATUS[0]}
if grep -Eq "RuntimeWarning: coroutine .* was never awaited" pytest.log; then
echo "Failure: Detected unawaited coroutine warning in pytest output."
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ coverage.xml
.hypothesis/
.pytest_cache/
test-reports/
test.lock

# Translations
*.mo
Expand Down
7 changes: 2 additions & 5 deletions acapy_agent/admin/request_context.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,6 @@
from ..config.injector import InjectionError, Injector, InjectType
from ..config.settings import Settings
from ..core.profile import Profile, ProfileSession
from ..utils.classloader import DeferLoad

IN_MEM = DeferLoad("acapy_agent.core.in_memory.InMemoryProfile")


class AdminRequestContext:
Expand Down Expand Up @@ -112,10 +109,10 @@ def update_settings(self, settings: Mapping[str, object]):

@classmethod
def test_context(
cls, session_inject: Optional[dict] = None, profile: Optional[Profile] = None
cls, session_inject: dict, profile: Profile
) -> "AdminRequestContext":
"""Quickly set up a new admin request context for tests."""
ctx = AdminRequestContext(profile or IN_MEM.resolved.test_profile())
ctx = AdminRequestContext(profile)
setattr(ctx, "session_inject", {} if session_inject is None else session_inject)
setattr(ctx, "session", ctx._test_session)
return ctx
Expand Down
Loading
Loading