Skip to content

Deploy tab endpoints (merge, GGUF export, GitHub push) not covered by integration tests #38

@SahilKumar75

Description

@SahilKumar75

Context

The 7-step wizard's Deploy tab (step 7) calls several API endpoints that were added in the recent wizard implementation. These endpoints exist in app/api.py but have no test coverage in tests/.

Uncovered endpoints

Endpoint Method Purpose
/api/jobs/{id}/merge POST Merge adapter into base model
/api/jobs/{id}/export-gguf GET Convert merged model to GGUF
/api/jobs/{id}/push-github POST Push adapter to GitHub repo
/api/jobs/{id}/push-hub POST Push adapter to HF Hub
/api/jobs/{id}/commentary GET Generate training summary commentary
/api/jobs/{id}/eval POST Run evaluation on fine-tuned model
/api/jobs/{id}/infer POST Run inference for test-chat

Tasks

  • Add integration tests for each endpoint in tests/test_api.py
  • Mock Celery tasks and file-system calls as done in existing tests
  • Cover both success (200) and error (404 job not found, 500 task failure) paths
  • Ensure no real model downloads occur in CI (use pytest-mock / unittest.mock)

Reference

Existing patterns in tests/test_api.py and tests/test_workers.py.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions