Skip to content

feat: add working e2e tests for chunk upload/download#1

Closed
mickvandijke wants to merge 2 commits intoWithAutonomi:mainfrom
mickvandijke:feat/e2e-chunk-tests
Closed

feat: add working e2e tests for chunk upload/download#1
mickvandijke wants to merge 2 commits intoWithAutonomi:mainfrom
mickvandijke:feat/e2e-chunk-tests

Conversation

@mickvandijke
Copy link
Copy Markdown
Collaborator

Summary

  • Add automatic test isolation via random ports (20000-60000) and unique temp directories
  • Implement working e2e tests for chunk store/retrieve operations
  • Fix dual-stack IPv6 binding issues in test harness
  • Refactor to follow coding standards (no magic numbers, module-level imports)

Changes

Test Isolation (commit 1)

  • Random port generation prevents test pollution in parallel runs
  • Each test gets a unique temp directory (/tmp/saorsa_test_{random})
  • Extracted all magic numbers into named constants

Chunk Tests (commit 2)

Test Description
test_chunk_store_retrieve_small Store and retrieve 1KB chunk
test_chunk_store_retrieve_large Store and retrieve 4MB chunk
test_chunk_reject_oversized Reject >4MB chunks (ignored - validation pending)

Test Results

test result: ok. 38 passed; 0 failed; 47 ignored

🤖 Generated with Claude Code

mickvandijke and others added 2 commits January 28, 2026 10:28
- Generate random ports (20000-60000) for each test run
- Create unique temp directories with random suffix
- Extract magic numbers into named constants
- Move imports to module level per coding standards
- Fix dual-stack IPv6 binding issues

This prevents test pollution when running tests in parallel.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Implement test_chunk_store_retrieve_small (1KB chunk)
- Implement test_chunk_store_retrieve_large (4MB max chunk)
- Add test_chunk_reject_oversized (ignored - validation pending)
- Move imports to module level per coding standards
- Extract magic numbers into named constants

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@dirvine
Copy link
Copy Markdown
Collaborator

dirvine commented Jan 28, 2026

@claude please review this now

@dirvine
Copy link
Copy Markdown
Collaborator

dirvine commented Jan 28, 2026

@claude please review this PR

@claude
Copy link
Copy Markdown

claude bot commented Jan 28, 2026

Claude encountered an error —— View job

Command failed: git fetch origin --depth=20 feat/e2e-chunk-tests

I'll analyze this and get back to you.

@dirvine
Copy link
Copy Markdown
Collaborator

dirvine commented Jan 28, 2026

@claude please review this PR (testing fork PR fix)

@claude
Copy link
Copy Markdown

claude bot commented Jan 28, 2026

Claude encountered an error —— View job

Command failed: git fetch origin --depth=20 feat/e2e-chunk-tests

I'll analyze this and get back to you.

@dirvine
Copy link
Copy Markdown
Collaborator

dirvine commented Jan 28, 2026

@claude please review this PR (using fork with fix)

@claude
Copy link
Copy Markdown

claude bot commented Jan 28, 2026

Claude encountered an error —— View job

Failed with exit code 128

I'll analyze this and get back to you.

@mickvandijke
Copy link
Copy Markdown
Collaborator Author

Closing to recreate with head branch from saorsa-labs/saorsa-node

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants