test(evm-wallet-experiment): Improve docker e2e test logging#930
Open
test(evm-wallet-experiment): Improve docker e2e test logging#930
Conversation
Tee entrypoint stdout/stderr to /logs/<service-name>.log so per-service logs persist beyond container lifetime and are accessible on the host. Replace the named ocap-logs volume with a bind-mount to ../logs so the host can read log files directly after a test run without docker cp. Add docker:ensure-logs script (mkdir -p logs) and call it from docker:up and docker:interactive:up so the bind-mount target always exists before the stack starts.
…tests Write structured pass/fail results to logs/test-results.json so failures can be inspected without parsing terminal output.
Contributor
Coverage Report
File CoverageNo changed files found. |
rekmarks
requested changes
Apr 10, 2026
|
|
||
| // Tee stdout/stderr to a file so logs are accessible on the host via the | ||
| // bind-mounted logs directory even after the container exits. | ||
| mkdirSync('/logs', { recursive: true }); |
Member
There was a problem hiding this comment.
As written, this would create /logs at the system root.
Suggested change
| mkdirSync('/logs', { recursive: true }); | |
| mkdirSync('./logs', { recursive: true }); |
Member
There was a problem hiding this comment.
Likewise for the stream below.
Contributor
Author
There was a problem hiding this comment.
Yes, but it's the root of the container, not the root of whoever runs yarn docker:up
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds logging infrastructure to the
evm-wallet-experimentdocker e2e suite for better failure analysis.Kernel service logs on the host — the entrypoint now tees stdout/stderr to
/logs/<service-name>.logvia astream.writewrapper before the process starts. The namedocap-logsvolume is replaced with a bind-mount topackages/evm-wallet-experiment/logs/, so all service logs are readable on the host immediately afterdocker:down(or a test failure).Structured test results — the docker vitest config gains a JSON reporter writing
logs/test-results.json. This lets agents and CI inspect pass/fail state and error messages without parsing terminal output.Test plan
yarn workspace @ocap/evm-wallet-experiment test:e2e:docker, then inspectpackages/evm-wallet-experiment/logs/— confirm per-service.logfiles andtest-results.jsonare present on the hostNote
Low Risk
Low risk: changes are limited to Docker E2E test scaffolding (log mounts, entrypoint logging, and Vitest reporting) with no production runtime or protocol logic changes.
Overview
Improves Docker E2E debuggability for
evm-wallet-experimentby persisting logs and test outputs on the host.Compose now bind-mounts
packages/evm-wallet-experiment/logs/to/logs(replacing theocap-logsvolume), the kernel entrypoint tees stdout/stderr into/logs/<service-name>.log, anddocker:up/docker:interactive:upensure thelogs/directory exists.Docker Vitest runs now emit a JSON report to
logs/test-results.jsonvia thejsonreporter.Reviewed by Cursor Bugbot for commit 31fa169. Bugbot is set up for automated code reviews on this repo. Configure here.