[PR #463] [MERGED] fix: harden update/reporting and eliminate zero-coverage packages #544

Closed
opened 2026-02-26 22:31:27 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/rudrankriyam/App-Store-Connect-CLI/pull/463
Author: @rudrankriyam
Created: 2/9/2026
Status: Merged
Merged: 2/10/2026
Merged by: @rudrankriyam

Base: mainHead: audit/fix-security-and-test-gaps


📝 Commits (10+)

  • f83a3ba fix: harden update/reporting paths and raise CLI test coverage
  • c87c9de test: add phase 1 coverage for utility command packages
  • b3d0428 test: add phase 2 coverage for identity and metadata commands
  • d6afb74 test: add phase 3 smoke coverage for release command families
  • 69af862 test: add phase 4 coverage for commerce and operational commands
  • 03b9a96 test: add phase 5 coverage for game center and xcode cloud
  • 07a6392 test: add phase 6 main package coverage and finalize plan
  • 2971db9 test: add phase 7 behavior coverage for high-risk packages
  • d27ecd3 test: add phase 8 API interaction coverage for core CLI flows
  • badf871 test: add phase 9 negative-path API coverage for core flows

📊 Changes

105 files changed (+20915 additions, -20 deletions)

View changed files

cmd/run_additional_test.go (+228 -0)
internal/asc/types/resources_test.go (+70 -0)
internal/cli/accessibility/accessibility_test.go (+89 -0)
internal/cli/actors/actors_test.go (+60 -0)
internal/cli/agerating/age_rating_test.go (+84 -0)
internal/cli/agreements/agreements_test.go (+87 -0)
internal/cli/androidiosmapping/android_ios_mapping_test.go (+29 -0)
internal/cli/app_events/app_events_test.go (+34 -0)
internal/cli/appclips/app_clips_test.go (+33 -0)
internal/cli/apps/helpers_normalization_test.go (+127 -0)
internal/cli/assets/assets_test.go (+27 -0)
internal/cli/auth/auth_test.go (+688 -0)
internal/cli/betaapplocalizations/beta_app_localizations_test.go (+23 -0)
internal/cli/betabuildlocalizations/beta_build_localizations_test.go (+23 -0)
internal/cli/buildbundles/build_bundles_test.go (+26 -0)
internal/cli/buildlocalizations/build_localizations_test.go (+20 -0)
internal/cli/builds/builds_expire_all_test.go (+143 -0)
internal/cli/categories/categories_test.go (+67 -0)
internal/cli/cmdtest/alternative_distribution_next_validation_test.go (+272 -0)
internal/cli/cmdtest/analytics_next_validation_test.go (+288 -0)

...and 80 more files

📄 Description

Summary

  • Preserve the existing hardening changes for update/reporting paths (fail-closed checksum handling and safer JUnit report writing).
  • Add a phased coverage expansion tracked in plan.md, with package-local tests added across command families one phase at a time.
  • Cover all packages that were previously at 0.0% including large command surfaces (gamecenter, xcodecloud) and the root package (main) via testable helper seams without changing CLI behavior.
  • Bring the branch to a state where short coverage runs no longer report any package at 0.0%.

Test plan

  • make format
  • make lint
  • make test
  • go test -short -coverprofile=coverage.out ./...
  • Verify no coverage: 0.0% of statements packages remain

Phase commits

  • c87c9de phase 1 coverage
  • b3d0428 phase 2 coverage
  • d6afb74 phase 3 coverage
  • 69af862 phase 4 coverage
  • 03b9a96 phase 5 coverage
  • 07a6392 phase 6 coverage

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/rudrankriyam/App-Store-Connect-CLI/pull/463 **Author:** [@rudrankriyam](https://github.com/rudrankriyam) **Created:** 2/9/2026 **Status:** ✅ Merged **Merged:** 2/10/2026 **Merged by:** [@rudrankriyam](https://github.com/rudrankriyam) **Base:** `main` ← **Head:** `audit/fix-security-and-test-gaps` --- ### 📝 Commits (10+) - [`f83a3ba`](https://github.com/rudrankriyam/App-Store-Connect-CLI/commit/f83a3baec25cc30e18eb28ff71afcd865c544c9e) fix: harden update/reporting paths and raise CLI test coverage - [`c87c9de`](https://github.com/rudrankriyam/App-Store-Connect-CLI/commit/c87c9de0bd533c30a73bb94fc837a28330cfe57b) test: add phase 1 coverage for utility command packages - [`b3d0428`](https://github.com/rudrankriyam/App-Store-Connect-CLI/commit/b3d042818b8732ce568628f90636b1de8dc73a09) test: add phase 2 coverage for identity and metadata commands - [`d6afb74`](https://github.com/rudrankriyam/App-Store-Connect-CLI/commit/d6afb7499678ed38d3002e87e57404b9cf6133ea) test: add phase 3 smoke coverage for release command families - [`69af862`](https://github.com/rudrankriyam/App-Store-Connect-CLI/commit/69af8622df54f1770e747fe672319f4a36020455) test: add phase 4 coverage for commerce and operational commands - [`03b9a96`](https://github.com/rudrankriyam/App-Store-Connect-CLI/commit/03b9a968020cbb06322e168f9560cb4658fecbbd) test: add phase 5 coverage for game center and xcode cloud - [`07a6392`](https://github.com/rudrankriyam/App-Store-Connect-CLI/commit/07a63928937349b32a9533229024d39f0be6bf75) test: add phase 6 main package coverage and finalize plan - [`2971db9`](https://github.com/rudrankriyam/App-Store-Connect-CLI/commit/2971db90a131d9ee9e539d52f7798fd9b79acc3d) test: add phase 7 behavior coverage for high-risk packages - [`d27ecd3`](https://github.com/rudrankriyam/App-Store-Connect-CLI/commit/d27ecd3c95c06afc51bd1e6beca1a7e22cace281) test: add phase 8 API interaction coverage for core CLI flows - [`badf871`](https://github.com/rudrankriyam/App-Store-Connect-CLI/commit/badf871435e069360b63bd0ae04a6130251f7e35) test: add phase 9 negative-path API coverage for core flows ### 📊 Changes **105 files changed** (+20915 additions, -20 deletions) <details> <summary>View changed files</summary> ➕ `cmd/run_additional_test.go` (+228 -0) ➕ `internal/asc/types/resources_test.go` (+70 -0) ➕ `internal/cli/accessibility/accessibility_test.go` (+89 -0) ➕ `internal/cli/actors/actors_test.go` (+60 -0) ➕ `internal/cli/agerating/age_rating_test.go` (+84 -0) ➕ `internal/cli/agreements/agreements_test.go` (+87 -0) ➕ `internal/cli/androidiosmapping/android_ios_mapping_test.go` (+29 -0) ➕ `internal/cli/app_events/app_events_test.go` (+34 -0) ➕ `internal/cli/appclips/app_clips_test.go` (+33 -0) ➕ `internal/cli/apps/helpers_normalization_test.go` (+127 -0) ➕ `internal/cli/assets/assets_test.go` (+27 -0) ➕ `internal/cli/auth/auth_test.go` (+688 -0) ➕ `internal/cli/betaapplocalizations/beta_app_localizations_test.go` (+23 -0) ➕ `internal/cli/betabuildlocalizations/beta_build_localizations_test.go` (+23 -0) ➕ `internal/cli/buildbundles/build_bundles_test.go` (+26 -0) ➕ `internal/cli/buildlocalizations/build_localizations_test.go` (+20 -0) ➕ `internal/cli/builds/builds_expire_all_test.go` (+143 -0) ➕ `internal/cli/categories/categories_test.go` (+67 -0) ➕ `internal/cli/cmdtest/alternative_distribution_next_validation_test.go` (+272 -0) ➕ `internal/cli/cmdtest/analytics_next_validation_test.go` (+288 -0) _...and 80 more files_ </details> ### 📄 Description ## Summary - Preserve the existing hardening changes for update/reporting paths (fail-closed checksum handling and safer JUnit report writing). - Add a phased coverage expansion tracked in `plan.md`, with package-local tests added across command families one phase at a time. - Cover all packages that were previously at `0.0%` including large command surfaces (`gamecenter`, `xcodecloud`) and the root package (`main`) via testable helper seams without changing CLI behavior. - Bring the branch to a state where short coverage runs no longer report any package at `0.0%`. ## Test plan - [x] `make format` - [x] `make lint` - [x] `make test` - [x] `go test -short -coverprofile=coverage.out ./...` - [x] Verify no `coverage: 0.0% of statements` packages remain ## Phase commits - [x] `c87c9de` phase 1 coverage - [x] `b3d0428` phase 2 coverage - [x] `d6afb74` phase 3 coverage - [x] `69af862` phase 4 coverage - [x] `03b9a96` phase 5 coverage - [x] `07a6392` phase 6 coverage --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-26 22:31:27 +03:00
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.

Dependencies

No dependencies set.

Reference
starred/App-Store-Connect-CLI#544
No description provided.