Skip to content

test: cover JSON export CI progress and CaseAwarePath cache refresh#314

Draft
cursor[bot] wants to merge 2 commits into
masterfrom
impl/missing-test-coverage-3f4d
Draft

test: cover JSON export CI progress and CaseAwarePath cache refresh#314
cursor[bot] wants to merge 2 commits into
masterfrom
impl/missing-test-coverage-3f4d

Conversation

@cursor
Copy link
Copy Markdown
Contributor

@cursor cursor Bot commented Jun 2, 2026

Risky behavior now covered

  • Installation JSON export progress in CI/automation (resource_json.py): When CI or GITHUB_ACTIONS is set, progress must log via logger.info instead of carriage-return stderr updates. Without this, GitHub Actions and log aggregators miss percentage milestones even when stderr reports as a TTY.
  • Case-insensitive directory cache (path.py): clear_cache() after directory structure changes so CaseAwarePath re-resolves segments on POSIX filesystems.

Test files added/updated

  • Libraries/PyKotor/tests/cli/test_json_commands.py — four tests for _supports_live_progress and _ExportProgressReporter (CI vs TTY behavior).
  • Libraries/PyKotor/tests/common/test_case_aware_path.py — POSIX regression for clear_cache() after directory mutations.

Why these tests materially reduce regression risk

The JSON export CI fix landed in c7e573d1d with only an integration assertion tweak; these unit tests lock the env-gating contract so a future refactor cannot silently restore \r live updates in automation. The path cache test guards case-aware resolution used by capsules, talk tables, TSLPatcher, and installation tooling after merged PR #151.

Open in Web View Automation 

cursoragent and others added 2 commits June 2, 2026 10:04
Co-authored-by: PuritanWizard <th3w1zard1@users.noreply.github.com>
Co-authored-by: PuritanWizard <th3w1zard1@users.noreply.github.com>
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 2, 2026

Message that will be displayed on users' first pull request

@github-actions github-actions Bot added python Pull requests that update python code libraries size/M Medium PR (100-300 lines) labels Jun 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

libraries python Pull requests that update python code size/M Medium PR (100-300 lines)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant