Skip to content

test : add unit tests for plugin_health_dashboard script helpers #2071

Description

@tmdeveloper007

Summary of What Needs to be Done:

The scripts/plugin_health_dashboard.py module contains four pure helper functions (safe_relative_path, discover_plugins, build_report, format_markdown) that generate plugin health reports from metadata.json and parser.py files. These functions are currently untested.

Changes that Need to be Made:

Add testing/backend/unit/test_plugin_health_dashboard.py with tests for:

  • safe_relative_path: normal case, exact match, outside-base case (returns absolute path), deeply nested paths
  • discover_plugins: returns list, detects missing parser, handles invalid JSON, sorts by name, empty directory
  • build_report: summary counts (total/with-parser/without), category aggregation, empty case
  • format_markdown: summary section content, alphabetical category order, plugin table with parser status

Impact that it would Provide:

  • Prevents regressions in plugin health reporting used by maintainers
  • Validates markdown output format
  • Ensures discover_plugins correctly categorizes plugins

Note: This task is being handled by tmdeveloper007 — please assign to that account when picking it up.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:ciCI, tooling, or automation workgood first issueFriendly starter issue for first-time contributorslevel:beginner20 pts difficulty label for small beginner-friendly PRstype:testingTesting work category bonus label

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions