ComfyUI/tests-unit/assets_test
Matt Miller f7558232fa
Some checks are pending
Python Linting / Run Ruff (push) Waiting to run
Python Linting / Run Pylint (push) Waiting to run
refactor(assets): extract cursor JSON escaping helper; size wire cap above per-field caps
Addresses review feedback on cursor.py:

- Extract the inline escape chain into _apply_wire_compatible_json_escapes()
  with a comment pinning it to the wire format's escape set, so the parity
  intent is explicit rather than reading as an ad-hoc transform.
- Raise MAX_ENCODED_CURSOR_LENGTH to 8192 (comfortably above the ~5.2KB
  worst-case the per-field caps can produce) and drop the mint-time length
  guard. Encoder/decoder symmetry now holds by construction: the encoder
  can't produce a cursor the decode path rejects, so there is no confusing
  user-visible 'cursor too long' failure at mint time.
- Rewrite the two over-wire-cap tests to assert worst-case multibyte and
  escape-heavy values mint and round-trip, instead of being rejected.
2026-06-08 16:56:10 -07:00
..
queries feat(assets): bind cursor to sort order + Go-compat JSON escaping 2026-05-20 13:43:09 -07:00
services refactor(assets): extract cursor JSON escaping helper; size wire cap above per-field caps 2026-06-08 16:56:10 -07:00
conftest.py Emit hash alongside asset_hash on all Asset responses (#13739) 2026-05-25 11:21:35 -07:00
helpers.py Emit hash alongside asset_hash on all Asset responses (#13739) 2026-05-25 11:21:35 -07:00
test_assets_missing_sync.py Emit hash alongside asset_hash on all Asset responses (#13739) 2026-05-25 11:21:35 -07:00
test_crud.py Emit hash alongside asset_hash on all Asset responses (#13739) 2026-05-25 11:21:35 -07:00
test_downloads.py refactor(assets): modular architecture + async two-phase scanner & background seeder (#12621) 2026-03-07 20:37:25 -05:00
test_file_utils.py refactor(assets): modular architecture + async two-phase scanner & background seeder (#12621) 2026-03-07 20:37:25 -05:00
test_list_cursor.py fix(assets): address ultrareview findings on cursor pagination 2026-05-21 14:29:27 -07:00
test_list_filter.py Emit hash alongside asset_hash on all Asset responses (#13739) 2026-05-25 11:21:35 -07:00
test_metadata_filters.py Assets Part 2 - add more endpoints (#12125) 2026-01-31 02:22:05 -05:00
test_prune_orphaned_assets.py refactor(assets): modular architecture + async two-phase scanner & background seeder (#12621) 2026-03-07 20:37:25 -05:00
test_sync_references.py refactor(assets): modular architecture + async two-phase scanner & background seeder (#12621) 2026-03-07 20:37:25 -05:00
test_tags_api.py refactor(assets): modular architecture + async two-phase scanner & background seeder (#12621) 2026-03-07 20:37:25 -05:00
test_uploads.py Emit hash alongside asset_hash on all Asset responses (#13739) 2026-05-25 11:21:35 -07:00