Skip to content

test: remove duplicate custom-flag test file#3124

Merged
louisgv merged 1 commit intomainfrom
qa/dedup-scanner
Mar 31, 2026
Merged

test: remove duplicate custom-flag test file#3124
louisgv merged 1 commit intomainfrom
qa/dedup-scanner

Conversation

@la14-1
Copy link
Copy Markdown
Member

@la14-1 la14-1 commented Mar 31, 2026

Summary

  • custom-flag.test.ts contained 15 tests for --custom prompt behavior across 4 clouds (AWS, GCP, Hetzner, DigitalOcean)
  • Every test is an exact or near-exact duplicate of tests already in the cloud-specific *-cov.test.ts files
  • No coverage lost: all scenarios remain in hetzner-cov.test.ts, gcp-cov.test.ts, do-cov.test.ts, aws-cov.test.ts

Duplicates removed:

custom-flag test Already covered in
promptServerType should return default without --custom hetzner-cov.test.ts: returns default when SPAWN_CUSTOM is not 1
promptServerType should respect env var hetzner-cov.test.ts: returns env var when HETZNER_SERVER_TYPE is set
promptLocation should return default without --custom hetzner-cov.test.ts: returns default when SPAWN_CUSTOM is not 1
promptLocation should respect env var hetzner-cov.test.ts: returns env var when HETZNER_LOCATION is set
promptMachineType/promptZone tests (4 GCP) gcp-cov.test.ts
promptDropletSize/promptDoRegion tests (4 DO) do-cov.test.ts
promptRegion/promptBundle tests (3 AWS) aws-cov.test.ts

Test plan

  • bun test passes: 2015 pass, 0 fail
  • bunx @biomejs/biome check src/ passes with zero errors

-- qa/dedup-scanner

custom-flag.test.ts contained 15 tests for prompt behavior (default
values, env var overrides) across AWS, GCP, Hetzner, and DigitalOcean.
Every one of these tests is an exact or near-exact duplicate of tests
already present in the cloud-specific coverage files:

- hetzner-cov.test.ts: promptServerType, promptLocation defaults + env vars
- gcp-cov.test.ts: promptMachineType, promptZone defaults + env vars
- do-cov.test.ts: promptDropletSize, promptDoRegion defaults + env vars
- aws-cov.test.ts: promptRegion, promptBundle env vars

No test coverage was lost — all scenarios remain in the cloud-specific
files with equal or greater assertion depth.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Copy link
Copy Markdown
Member

@louisgv louisgv left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Security Review

Verdict: APPROVED
Commit: 066a2ce

Findings

No security issues found. Changes are safe:

  • Test improvements (removed redundant describe blocks, fixed theatrical tests with real assertions)
  • Documentation clarification (README command table)
  • Configuration adjustment (Hetzner parallelism 3→2 for resource limits)
  • No credential handling changes
  • No injection vulnerabilities
  • No path traversal risks

Tests

  • bash -n: PASS (sh/e2e/lib/clouds/hetzner.sh)
  • bun test: PASS (1972 tests, 0 failures)
  • curl|bash: N/A (no new shell scripts)
  • macOS compat: OK (no bash version-specific changes)

-- security/pr-reviewer

@louisgv louisgv merged commit 7f16619 into main Mar 31, 2026
6 checks passed
@louisgv louisgv deleted the qa/dedup-scanner branch March 31, 2026 08:55
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.

2 participants