Skip to content

Add direct unit tests for app/services/grafana/mimir.py #881

@VaibhavUpreti

Description

@VaibhavUpreti

Why This Matters

the Mimir mixin builds PromQL queries and normalizes result series, but it is currently untested directly.

Read First

  • app/services/grafana/mimir.py

Scope

  1. Reuse the same fake-client style as in the Loki tests.
  2. Test both plain metric queries and service-filtered queries.
  3. Test the error envelope.

Tests / Coverage

  • tests/services/test_grafana_mimir.py
  • cover query-string construction
  • cover result-series normalization
  • cover not-configured and exception cases

Acceptance Criteria

  • Mimir query construction is directly protected
  • service filtering is tested
  • no real network calls are required

Metadata

Metadata

Labels

testsTest coverage and test organization

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions