Skip to content

fix: overhaul tests #286

Closed
1 of 1 issue completed
Closed

Description

@jakelorocco

We currently have a lot of duplicate tests that perform unnecessary requests and generations. We should refactor our tests to allow easier use of mocked inputs / outputs along with de-duplicating the amount of tests between the backends.

We should have a few types of tests:

  • Conformance tests- for each backend, we should ensure that we receive the expected response format for a given input (ie structured outputs, tool requests, etc...)
  • Backend unit tests- for each backend, we should mock these response values and ensure that our backends process these responses as expected
  • Std library tests- these resemble regular unit tests; if generation is required, we should mock that generation

We should also allow mocking to be disabled so that the full test suite can be run with real requests.

These changes should decouple our testing of the standard library / backend functionality from the tests that actually check LLM generation. This should allow us to actually run unit tests for backends during our regular test suite and only require special testing pipelines for the conformance tests.

Sub-issues

Sub-issues

1 of 1 Issues completed
Loading 1 sub-issues

Activity

  1. self-assigned this
    on Jan 5, 2026
  2. nrfulton commented on Jan 6, 2026

    @nrfulton
    Member
    • Tests (sometimes? always?) fail to locally without CICD=1 due to multiple models getting loaded into memory. Likely from huggingface-related tests.
  3. avinash2692 commented on Jan 6, 2026

    @avinash2692
    Contributor

    I also have some testing cleanup code that I could add to this PR. This would entail:

    • Skip entire modules with all-qualitative Tests in CI with pytestmark
    • Add a some universal memory cleanup fixtures to be run after each module.

    This would explicitly be for the CICD==1 case

  4. self-assigned this
    on Jan 6, 2026
  5. jakelorocco commented on Jan 7, 2026

    @jakelorocco
    ContributorAuthor

    From in person discussion with @nrfulton: We should have a CICD mode that mocks most if not all generation request. For full releases, we will run without mocks so that we can ensure API conformance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions