Skip to content

[Feature]: Add Unit Tests for the UI Rendering Engine #30

Description

@pipe1os

Problem Description

src/modelinfo/ui.py has only 7% test coverage. While testing terminal UI output can be tricky, the rich library provides a Console(record=True) feature that allows you to capture terminal output to a string for assertions.

Proposed Solution

  1. Create tests/test_ui.py.
  2. Provide dummy info dictionaries (like what analyze_model returns).
  3. Capture the rich console output and assert that critical strings (like the correct "VRAM (est):", Color-coded warnings, and model parameter counts) are rendered properly.

Alternatives Considered

No response

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requesthelp wantedExtra attention is needed

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions