Skip to content

test: add integration test for RAG query input length validation#890

Open
Pcmhacker-piro wants to merge 1 commit into
SdSarthak:mainfrom
Pcmhacker-piro:fix/rag-query-length-validation
Open

test: add integration test for RAG query input length validation#890
Pcmhacker-piro wants to merge 1 commit into
SdSarthak:mainfrom
Pcmhacker-piro:fix/rag-query-length-validation

Conversation

@Pcmhacker-piro
Copy link
Copy Markdown

Summary

Closes #

Type of Change

  • Bug fix
  • New feature
  • Documentation update
  • Refactor
  • Tests
  • Infra / CI

Checklist

  • I have read [CONTRIBUTING.md](../CONTRIBUTING.a## Summary

    Closes fix: missing input length validation on POST /rag/query endpoint #724

    This PR adds an integration test to verify the length and presence validation of the question field on the POST /api/v1/rag/query endpoint. It ensures that queries longer than
    2000 characters or empty queries are correctly rejected by the server with HTTP 422 Unprocessable Entity.

    Type of Change

    • Bug fix
    • New feature
    • Documentation update
    • Refactor
    • Tests
    • Infra / CI

    Checklist

    • I have read CONTRIBUTING.md
    • My code follows the project style (PEP 8 for Python, ESLint for TS)
    • I have added/updated tests where relevant
    • pytest backend/tests/ passes locally
    • I have not committed .env or any secrets
    • I have updated documentation if needed

    Screenshots (if UI change)

    md)
  • My code follows the project style (PEP 8 for Python, ESLint for TS)

  • I have added/updated tests where relevant

  • pytest backend/tests/ passes locally

  • I have not committed .env or any secrets

  • I have updated documentation if needed

Screenshots (if UI change)

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.

fix: missing input length validation on POST /rag/query endpoint

1 participant