Skip to content

test(api): cover SearchService limit/offset clamp bounds (#1252) - #1280

Open
Adithya9605 wants to merge 1 commit into
Vatix-Protocol:mainfrom
Adithya9605:test/search-service-pagination-clamp
Open

Adithya9605 wants to merge 1 commit into
Vatix-Protocol:mainfrom
Adithya9605:test/search-service-pagination-clamp

Conversation

@Adithya9605

Copy link
Copy Markdown

Summary

Adds table-driven tests for the limit clamp (50, 51, Infinity, 1, 0, negative, NaN, fractional) and offset clamp (negative, NaN, fractional, large). Tests only; no production code changed.

Related issue

Type of change

  • Chore / refactor

Contract drift check

  • I checked this change against CONTRACTS.md and there is no contract drift

How was this tested?

Ran search.service.spec.ts in an isolated ts-jest sandbox: the 12 new cases pass. Two existing tests (ranks pools by volume descending... and guards the volume24h cast...) fail on unmodified main in that sandbox too, so they are not caused by this change.

Checklist

  • CI passes (lint + tests + build)
  • Self-reviewed the diff
  • Added or updated tests where relevant
  • Docs updated if needed
  • No secrets or credentials committed

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.

apps/api: SearchService.search clamps limit but has no spec for the clamp bounds

1 participant