Add test coverage and fix stale graph references across all SDKs#16
Merged
Conversation
- antd-go: add 6 tests for wallet and external signer methods (WalletAddress, WalletBalance, WalletApprove, PrepareUpload, PrepareDataUpload, FinalizeUpload) using httptest mock daemon - antd-py: add 14 tests for REST client using threaded mock HTTP server — covers health, data, chunks, wallet, and error mapping (404→NotFoundError, 400→BadRequestError, 502→NetworkError) - antd-js: add 31 vitest tests for REST client with mocked fetch — covers all endpoints, error status mapping (7 codes), network errors, timeout handling, and constructor options All tests verified passing: Go 13/13, Python 14/14, JS 31/31. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- antd-rust: remove graph.proto from build.rs, delete dead 05-graph example, remove Cargo.toml example entry, update tests and examples to pass payment_mode parameter (added in prior commit), fix doctest - antd-csharp: remove graph.proto from csproj, add wallet and external signer stubs to gRPC client (NotSupportedException) All test suites now pass: Go: 35 pass | Python: 43 pass | JS: 31 pass | Rust: 55 pass PHP: 23 pass | Dart: 43 pass | C#: builds clean (integration tests) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- antd-zig: remove parseGraphEntry, GraphDescendant from json_helpers and 3 graph-related tests from tests.zig - antd-csharp: already fixed graph.proto in csproj (prior commit) - antd-kotlin: proto files copied by gradle copyProtos task (no graph) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- lib/build.gradle.kts: add afterEvaluate block to ensure generateProto depends on copyProtos (was running before proto files were copied) - lib/build.gradle.kts: add junit-platform-launcher to test runtime (was failing with "Failed to load JUnit Platform") - examples/build.gradle.kts: add kotlinx-coroutines-core dependency (examples use runBlocking which requires coroutines on classpath) Kotlin tests now pass: 7/7 (SmokeTests). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Tests run against a real antd daemon (default http://127.0.0.1:51105, override via ANTD_TEST_URL env var). All gracefully skip when no daemon is reachable, so CI still passes without infrastructure. - antd-go: 8 integration tests (health, error mapping for no-wallet, invalid address, missing upload_id, no-peers cost) - antd-py: 7 integration tests (health, BadRequestError for invalid hex, NotFoundError for valid-but-missing address, ServiceUnavailable for wallet ops, error for cost without peers) - antd-js: 8 integration tests (health, ServiceUnavailableError, BadRequestError, AntdError, NetworkError on unreachable port) Verified all 23 tests passing against antd in local mode (no wallet, no peers). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
22 tests covering all REST client operations: health, data (public/ private), chunks, wallet, archives, files, external signer, and error mapping for 6 HTTP status codes. Uses a lightweight HttpListener-based mock server — no external mocking libraries required. C# now has parity with the other SDK test suites. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Nic-dorman
added a commit
that referenced
this pull request
May 14, 2026
… on stop (#81) ant-devnet keeps anvil alive past Testnet::new scope via std::mem::forget on the AnvilInstance, then relies on graceful Drop at process exit to clean it up. SIGTERM/SIGKILL skip destructors, so every ant dev stop leaks one anvil child and one ~/.local/share/ant/nodes/<peer_id>/ tree for each of the spawned nodes. After a handful of start/stop or killed-mid-startup cycles, the LXC accumulates orphan anvils plus 100+ stale node dirs, and subsequent ant dev start runs flake or hang. This is a workaround at the ant-dev layer (Option B in #73). The proper fix lives in ant-devnet itself (Option A: tempfile::TempDir + tokio signal handler, mirroring how ant-clients MiniTestnet and ant-nodes tests/e2e/testnet.rs already do it) and will be a separate PR against WithAutonomi/ant-node. In ant dev stop now: - pkill anvil and antnode in addition to ant-devnet - rm -rf ~/.local/share/ant/nodes and ~/.local/share/ant/spill so the next start begins from a clean state - Centralise the pkill calls into a _pkill() helper No behaviour change on Windows (the pkill / rm paths are POSIX-only). Closes #16 (local task); helps mitigate #73 (upstream).
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.
Summary
394 total unit tests + 23 integration tests across 11 SDKs. No SDK has zero coverage.
Test plan
🤖 Generated with Claude Code