Skip to content

test: cover augmentation CLIs + fix broken console-script entry points (Tier B)#330

Open
voorhs wants to merge 1 commit into
devfrom
cov/tier-b-cli
Open

test: cover augmentation CLIs + fix broken console-script entry points (Tier B)#330
voorhs wants to merge 1 commit into
devfrom
cov/tier-b-cli

Conversation

@voorhs

@voorhs voorhs commented Jun 21, 2026

Copy link
Copy Markdown
Collaborator

What

Coverage series (follow-up to #325), Tier B — CLI entry points.

Adds tests driving the real main() of both augmentation CLIs (previously 0%):

  • autointent.generation.utterances._basic.cli (basic-aug)
  • autointent.generation.utterances._evolution.cli (evolution-aug)

Every collaborator (load_dataset, Generator, synthesizer templates, UtteranceGenerator / UtteranceEvolver / IncrementalUtteranceEvolver) is mocked at the cli module namespace, so argument parsing and control flow run for real with no dataset, network, or LLM access. Covered: en/ru template selection, regular-vs-incremental evolver branch, --async-mode forwarding, and the optional --output-repo push path.

Bonus fix (please review)

While writing these I found the [project.scripts] entry points are broken: they point at ...utterances.basic.cli / ...utterances.evolution.cli, but those modules don't exist — the packages are _basic / _evolution. As shipped, basic-aug and evolution-aug both fail with ModuleNotFoundError. Corrected to the real _-prefixed paths. This is a one-line-each packaging fix; happy to split it into its own PR if you'd prefer.

Notes

  • Tests live in the unit-tests CI job.
  • Verified locally with ruff check, ruff format --check, and mypy --strict (Python 3.10). Execution left to CI.

🤖 Generated with Claude Code

…ipt paths

Add tests driving the real `main()` of the `basic-aug` and `evolution-aug`
CLIs (previously 0%). Every collaborator (load_dataset, Generator, synthesizer
templates, UtteranceGenerator/UtteranceEvolver/IncrementalUtteranceEvolver) is
mocked at the cli module namespace, so argument parsing and control flow run for
real without any dataset, network, or LLM access. Covers the en/ru template
branches, the regular-vs-incremental evolver branch, async-mode forwarding, and
the optional push-to-hub path.

Also fix the `[project.scripts]` entry points, which pointed at
`...utterances.basic.cli` / `...utterances.evolution.cli` — modules that do not
exist (the packages are `_basic` / `_evolution`). As shipped, both console
scripts fail with ModuleNotFoundError; corrected to the real `_`-prefixed paths.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant