TEST-INFRA: [missing-test-levels] Add tests for actor module #1776

Open
opened 2026-04-02 23:47:36 +00:00 by freemo · 1 comment
Owner

The following files in the src/cleveragents/actor module are missing tests:

  • src/cleveragents/actor/__init__.py
  • src/cleveragents/actor/compiler.py
  • src/cleveragents/actor/config.py
  • src/cleveragents/actor/loader.py
  • src/cleveragents/actor/reconciliation.py
  • src/cleveragents/actor/registry.py
  • src/cleveragents/actor/role_validation.py
  • src/cleveragents/actor/schema.py
  • src/cleveragents/actor/yaml_template_engine.py

Metadata

  • Branch: test/missing-test-levels-actor-module
  • Commit Message: test(actor): add Behave, Robot, and ASV tests for actor module
  • Milestone: v3.8.0
  • Parent Epic: #933

Background and Context

The actor module in src/cleveragents/actor is missing all three required levels of testing as mandated by CONTRIBUTING.md's Multi-Level Testing Mandate:

  • Behave unit tests (in features/) — BDD/Gherkin scenarios covering unit-level behavior
  • Robot integration tests (in robot/) — integration tests using real services, no mocks
  • ASV performance benchmarks (in benchmarks/) — performance regression tracking

This violates the testing standards outlined in CONTRIBUTING.md, which states: "Every coding task must include or update tests at multiple levels: unit tests, integration tests, and performance benchmarks. Testing is non-optional and is part of the definition of done for any task."

The actor module is a core architectural component of CleverAgents — it provides the YAML-configured conversational unit abstraction (single LLM/agent or composed LangGraph of actors and tool nodes), including compilation, configuration, loading, reconciliation, registry management, role validation, schema definition, and YAML template engine. Comprehensive test coverage at all levels is essential.

Expected Behavior

The actor module has complete test coverage at all three required levels:

  1. Behave feature files with step implementations covering all module behaviors
  2. Robot integration test suites exercising real actor module dependencies
  3. ASV benchmarks tracking performance of key actor module operations

Acceptance Criteria

  • Behave feature files exist in features/ covering the actor module's public API and behaviors for all 9 files listed above
  • All Behave step definitions are fully implemented (no placeholder steps)
  • Robot integration test suites exist in robot/ for the actor module using real services (no mocks)
  • ASV performance benchmarks exist in benchmarks/ for key actor module operations (where applicable)
  • All new tests pass via the project's nox task runner
  • Test coverage for the actor module is >= 97%
  • All nox sessions pass (unit, integration, typecheck, lint, coverage)

Subtasks

  • Audit all 9 files in src/cleveragents/actor/ for untested code paths
  • Write Behave (Gherkin) unit test scenarios in features/ covering actor/__init__.py
  • Write Behave (Gherkin) unit test scenarios in features/ covering actor/compiler.py
  • Write Behave (Gherkin) unit test scenarios in features/ covering actor/config.py
  • Write Behave (Gherkin) unit test scenarios in features/ covering actor/loader.py
  • Write Behave (Gherkin) unit test scenarios in features/ covering actor/reconciliation.py
  • Write Behave (Gherkin) unit test scenarios in features/ covering actor/registry.py
  • Write Behave (Gherkin) unit test scenarios in features/ covering actor/role_validation.py
  • Write Behave (Gherkin) unit test scenarios in features/ covering actor/schema.py
  • Write Behave (Gherkin) unit test scenarios in features/ covering actor/yaml_template_engine.py
  • Write Robot Framework integration tests in robot/ for the actor module
  • Write ASV benchmark tests in benchmarks/ for the actor module (if applicable)
  • Add/update step definitions in features/steps/ as needed
  • Add/update mock implementations in features/mocks/ as needed (no mocks in production code)
  • Run nox -e unit_tests and confirm all scenarios pass
  • Run nox -e integration_tests and confirm all tests pass
  • Run nox -e coverage_report and confirm coverage >= 97%
  • Run nox -e typecheck and confirm zero Pyright errors
  • Run nox -e lint and confirm zero linting errors
  • Run full nox suite and confirm all sessions pass

Definition of Done

  • All subtasks above are checked off
  • Commit created with exact message: test(actor): add Behave, Robot, and ASV tests for actor module
  • Commit footer includes ISSUES CLOSED: #<this issue number>
  • Commit pushed to branch test/missing-test-levels-actor-module
  • Pull request submitted, reviewed, and merged
  • All nox stages pass
  • Coverage >= 97%

Automated by CleverAgents Bot
Supervisor: Test Infrastructure | Agent: ca-new-issue-creator

The following files in the `src/cleveragents/actor` module are missing tests: - `src/cleveragents/actor/__init__.py` - `src/cleveragents/actor/compiler.py` - `src/cleveragents/actor/config.py` - `src/cleveragents/actor/loader.py` - `src/cleveragents/actor/reconciliation.py` - `src/cleveragents/actor/registry.py` - `src/cleveragents/actor/role_validation.py` - `src/cleveragents/actor/schema.py` - `src/cleveragents/actor/yaml_template_engine.py` ## Metadata - **Branch**: `test/missing-test-levels-actor-module` - **Commit Message**: `test(actor): add Behave, Robot, and ASV tests for actor module` - **Milestone**: v3.8.0 - **Parent Epic**: #933 ## Background and Context The `actor` module in `src/cleveragents/actor` is missing all three required levels of testing as mandated by CONTRIBUTING.md's Multi-Level Testing Mandate: - **Behave** unit tests (in `features/`) — BDD/Gherkin scenarios covering unit-level behavior - **Robot** integration tests (in `robot/`) — integration tests using real services, no mocks - **ASV** performance benchmarks (in `benchmarks/`) — performance regression tracking This violates the testing standards outlined in CONTRIBUTING.md, which states: *"Every coding task must include or update tests at multiple levels: unit tests, integration tests, and performance benchmarks. Testing is non-optional and is part of the definition of done for any task."* The `actor` module is a core architectural component of CleverAgents — it provides the YAML-configured conversational unit abstraction (single LLM/agent or composed LangGraph of actors and tool nodes), including compilation, configuration, loading, reconciliation, registry management, role validation, schema definition, and YAML template engine. Comprehensive test coverage at all levels is essential. ## Expected Behavior The `actor` module has complete test coverage at all three required levels: 1. Behave feature files with step implementations covering all module behaviors 2. Robot integration test suites exercising real actor module dependencies 3. ASV benchmarks tracking performance of key actor module operations ## Acceptance Criteria - [ ] Behave feature files exist in `features/` covering the `actor` module's public API and behaviors for all 9 files listed above - [ ] All Behave step definitions are fully implemented (no placeholder steps) - [ ] Robot integration test suites exist in `robot/` for the `actor` module using real services (no mocks) - [ ] ASV performance benchmarks exist in `benchmarks/` for key `actor` module operations (where applicable) - [ ] All new tests pass via the project's nox task runner - [ ] Test coverage for the `actor` module is >= 97% - [ ] All nox sessions pass (unit, integration, typecheck, lint, coverage) ## Subtasks - [ ] Audit all 9 files in `src/cleveragents/actor/` for untested code paths - [ ] Write Behave (Gherkin) unit test scenarios in `features/` covering `actor/__init__.py` - [ ] Write Behave (Gherkin) unit test scenarios in `features/` covering `actor/compiler.py` - [ ] Write Behave (Gherkin) unit test scenarios in `features/` covering `actor/config.py` - [ ] Write Behave (Gherkin) unit test scenarios in `features/` covering `actor/loader.py` - [ ] Write Behave (Gherkin) unit test scenarios in `features/` covering `actor/reconciliation.py` - [ ] Write Behave (Gherkin) unit test scenarios in `features/` covering `actor/registry.py` - [ ] Write Behave (Gherkin) unit test scenarios in `features/` covering `actor/role_validation.py` - [ ] Write Behave (Gherkin) unit test scenarios in `features/` covering `actor/schema.py` - [ ] Write Behave (Gherkin) unit test scenarios in `features/` covering `actor/yaml_template_engine.py` - [ ] Write Robot Framework integration tests in `robot/` for the `actor` module - [ ] Write ASV benchmark tests in `benchmarks/` for the `actor` module (if applicable) - [ ] Add/update step definitions in `features/steps/` as needed - [ ] Add/update mock implementations in `features/mocks/` as needed (no mocks in production code) - [ ] Run `nox -e unit_tests` and confirm all scenarios pass - [ ] Run `nox -e integration_tests` and confirm all tests pass - [ ] Run `nox -e coverage_report` and confirm coverage >= 97% - [ ] Run `nox -e typecheck` and confirm zero Pyright errors - [ ] Run `nox -e lint` and confirm zero linting errors - [ ] Run full `nox` suite and confirm all sessions pass ## Definition of Done - [ ] All subtasks above are checked off - [ ] Commit created with exact message: `test(actor): add Behave, Robot, and ASV tests for actor module` - [ ] Commit footer includes `ISSUES CLOSED: #<this issue number>` - [ ] Commit pushed to branch `test/missing-test-levels-actor-module` - [ ] Pull request submitted, reviewed, and merged - [ ] All nox stages pass - [ ] Coverage >= 97% --- **Automated by CleverAgents Bot** Supervisor: Test Infrastructure | Agent: ca-new-issue-creator
freemo added this to the v3.8.0 milestone 2026-04-02 23:49:08 +00:00
Author
Owner

Issue triaged by project owner:

  • State: Verified
  • MoSCoW: MoSCoW/Could Have — test coverage improvement.

Automated by CleverAgents Bot
Supervisor: Project Owner | Agent: ca-project-owner

Issue triaged by project owner: - **State**: Verified - **MoSCoW**: MoSCoW/Could Have — test coverage improvement. --- **Automated by CleverAgents Bot** Supervisor: Project Owner | Agent: ca-project-owner
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
cleveragents/cleveragents-core#1776
No description provided.