Skip to content

Add comprehensive object_store test coverage (46 new tests)#21

Merged
s3rius merged 1 commit intomasterfrom
copilot/improve-object-store-test-coverage
Mar 25, 2026
Merged

Add comprehensive object_store test coverage (46 new tests)#21
s3rius merged 1 commit intomasterfrom
copilot/improve-object-store-test-coverage

Conversation

@s3rius
Copy link
Copy Markdown
Member

@s3rius s3rius commented Mar 25, 2026

New tests cover:

  • get_info(): fields verification (name, bucket, size, chunks, nuid, deleted, digest, description, headers, metadata, modified, link)
  • ObjectInfo.str() representation
  • seal(): sealing bucket and verifying sealed state prevents puts
  • list(): listing objects, empty bucket, iterator.next() with timeout
  • watch(): basic watch, with_history, without_history, multiple events, delete events, timeout, timedelta timeout
  • link_object() and link_bucket(): creating links and verifying ObjectLink fields
  • update_metadata(): description, rename, headers, metadata
  • put() with metadata, file path, custom chunk_size, all options combined, multi-value headers, empty data
  • get() with custom chunk_size
  • ObjectInfoIterator: aiter protocol
  • ObjectStoreConfig: all options, setters, defaults, full options creation
  • Error handling: get/get_info nonexistent objects, get nonexistent bucket
  • Multiple objects in a single bucket
  • Delete then get_info (verify deleted=True)
  • Overwrite preserves bucket info

Agent-Logs-Url: https://github.com/taskiq-python/natsrpy/sessions/e3f8e778-1ed5-4c2d-8191-b7bd8cf10425

New tests cover:
- get_info(): fields verification (name, bucket, size, chunks, nuid, deleted, digest, description, headers, metadata, modified, link)
- ObjectInfo.__str__() representation
- seal(): sealing bucket and verifying sealed state prevents puts
- list(): listing objects, empty bucket, iterator.next() with timeout
- watch(): basic watch, with_history, without_history, multiple events, delete events, timeout, timedelta timeout
- link_object() and link_bucket(): creating links and verifying ObjectLink fields
- update_metadata(): description, rename, headers, metadata
- put() with metadata, file path, custom chunk_size, all options combined, multi-value headers, empty data
- get() with custom chunk_size
- ObjectInfoIterator: __aiter__ protocol
- ObjectStoreConfig: all options, setters, defaults, full options creation
- Error handling: get/get_info nonexistent objects, get nonexistent bucket
- Multiple objects in a single bucket
- Delete then get_info (verify deleted=True)
- Overwrite preserves bucket info

Co-authored-by: s3rius <18153319+s3rius@users.noreply.github.com>
Agent-Logs-Url: https://github.com/taskiq-python/natsrpy/sessions/e3f8e778-1ed5-4c2d-8191-b7bd8cf10425
@s3rius s3rius merged commit 77ff25f into master Mar 25, 2026
8 checks passed
@s3rius s3rius deleted the copilot/improve-object-store-test-coverage branch March 25, 2026 15:43
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