plexus.scores.test_langgraphscore_routing module

LangGraphScore Conditional Routing Tests

This file contains tests specifically for LangGraphScore’s conditional routing functionality, including edge routing, conditions with fallback, and the newly discovered routing bugs.

Extracted from the massive LangGraphScore_test.py file for better maintainability.

plexus.scores.test_langgraphscore_routing.basic_routing_config()

Basic configuration for routing tests.

async plexus.scores.test_langgraphscore_routing.test_conditional_routing_actual_execution()

Test that actually executes a LangGraphScore workflow with conditional routing. This fills the gap left by existing tests that mock workflow.ainvoke().

IMPORTANT: This test exposes the broken conditional routing system.

async plexus.scores.test_langgraphscore_routing.test_conditional_routing_debug_logging()

Test that conditional routing debug logging actually captures real routing decisions. This verifies the debug infrastructure works when routing is executed.

async plexus.scores.test_langgraphscore_routing.test_conditional_routing_with_edge_fallback()

Test conditional routing with edge clause fallback by actually executing the workflow. This tests the more complex routing scenarios.

async plexus.scores.test_langgraphscore_routing.test_exact_production_bug_reproduction()

Test that uses the EXACT same configuration structure as production to reproduce the bug. This matches the CMG - EDU v1.0 scorecard’s “Computer w/ Internet” score configuration.

async plexus.scores.test_langgraphscore_routing.test_production_bug_actual_execution()

Test that reproduces the exact production bug by actually executing the workflow. This should expose the top-level output mapping override issue.

Based on GitHub Issue #80 where conditional outputs are overridden by top-level mappings.