Skip to content

[CI] Fix failing Pester tests in IntentRouter module #6

@POWDER-RANGER

Description

@POWDER-RANGER

Component

Intent Routing

Bug Description

Problem

The CI pipeline is failing with 34 Pester test failures in the IntentRouter module tests.

Failing Tests

  • IntentRouter.Service Selection tests (Claude, Perplexity selection)
  • IntentRouter.Parameter Extraction tests (URL, command extraction)
  • IntentRouter.Error Handling tests
  • IntentRouter.Confidence Scoring tests
  • PowerShellExecutor tests

Root Cause

Tests appear to be failing due to:

  1. Missing or incorrect mock setup for service selection logic
  2. Parameter extraction logic not matching test expectations
  3. Potential timing or state management issues in async operations

Expected Behavior

All Pester tests should pass in CI, with:

  • Proper mocking of external dependencies
  • Correct parameter extraction and validation
  • Appropriate error handling coverage
  • Reliable confidence scoring

Steps to Reproduce

  1. Run Invoke-Pester on tests/PowerShellExecutor.Tests.ps1
  2. Observe 34 test failures in IntentRouter module

Acceptance Criteria

  • All IntentRouter.Service Selection tests pass
  • All IntentRouter.Parameter Extraction tests pass
  • All IntentRouter.Error Handling tests pass
  • All IntentRouter.Confidence Scoring tests pass
  • CI pipeline shows green checkmark
  • Code coverage remains above 75%

Steps to Reproduce

  1. Check Actions tab on CONductOR repo
  2. View latest workflow run for "CI" workflow
  3. Click on "Run Pester Tests" job
  4. Observe 34 test failures in IntentRouter module tests

Error Messages / Logs

Severity

High (Major functionality broken)

CONductOR Version

No response

PowerShell Version

No response

Operating System

No response

Pre-submission Checklist

  • I have searched existing issues to avoid duplicates
  • I have included steps to reproduce
  • I have included error messages/logs if applicable

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions