Skip to content

Conversation

@rubenhoenle
Copy link
Member

@rubenhoenlerubenhoenle commented Oct 21, 2025

Description

relates to STACKITCLI-266 / #893

Testing

  1. With no DNS zones present in your STACKIT project validate the output of the zone list command:
    • stackit dns zone list -> Expected output: No zones found for project "xxx" matching the criteria
    • stackit dns zone list --output-format json -> expected valid JSON output
    • stackit dns zone list --output-format yaml -> expected valid YAML output
  2. Create a DNS zone: stackit dns zone create --name my-zone --dns-name www.my-zone.com
  3. Store the zone id into a env variable: export ZONE_ID="xxx"
  4. With a DNS zone present in your STACKIT project validate the output of the zone list command again:
    • stackit dns zone list -> Expected output: Table showing the available DNS zones
    • stackit dns zone list --output-format json -> expected valid JSON output
    • stackit dns zone list --output-format yaml -> expected valid YAML output
  5. With the default DNS records available in your DNS zone: Validate the output of the record-set list command:
    • stackit dns record-set list --zone-id $ZONE_ID -> Expected output: Table showing the default DNS zone record sets
    • stackit dns record-set list --zone-id $ZONE_ID --output-format json -> expected valid JSON output
    • stackit dns record-set list --zone-id $ZONE_ID --output-format yaml -> expected valid YAML output
  6. Cleanup
    • Delete the DNS zone you created: stackit dns zone delete $ZONE_ID

Checklist

  • Issue was linked above
  • Code format was applied: make fmt
  • Examples were added / adjusted (see e.g. here)
  • Docs are up-to-date: make generate-docs (will be checked by CI)
  • Unit tests got implemented or updated
  • Unit tests are passing: make test (will be checked by CI)
  • No linter issues: make lint (will be checked by CI)

@rubenhoenlerubenhoenle self-assigned this Oct 21, 2025
@rubenhoenlerubenhoenle requested a review from a team as a code ownerOctober 21, 2025 15:44
@github-actions
Copy link

This PR was marked as stale after 7 days of inactivity and will be closed after another 7 days of further inactivity. If this PR should be kept open, just add a comment, remove the stale label or push new commits to it.

@github-actions
Copy link

This PR was marked as stale after 7 days of inactivity and will be closed after another 7 days of further inactivity. If this PR should be kept open, just add a comment, remove the stale label or push new commits to it.

@rubenhoenlerubenhoenleforce-pushed the fix/STACKITCLI-266-dns-json-list branch from 2238a6d to 947eb73CompareNovember 14, 2025 09:18
@rubenhoenlerubenhoenle enabled auto-merge (squash) November 14, 2025 09:18
@rubenhoenlerubenhoenle merged commit 46b8905 into mainNov 14, 2025
5 checks passed
@rubenhoenlerubenhoenle deleted the fix/STACKITCLI-266-dns-json-list branch November 14, 2025 09:24
@github-actions
Copy link

Merging this branch will decrease overall coverage

Impacted PackagesCoverage Δ🤖
github.com/stackitcloud/stackit-cli/internal/cmd/dns/record-set/create56.34% (ø)
github.com/stackitcloud/stackit-cli/internal/cmd/dns/record-set/delete28.30% (ø)
github.com/stackitcloud/stackit-cli/internal/cmd/dns/record-set/describe70.59% (ø)
github.com/stackitcloud/stackit-cli/internal/cmd/dns/record-set/list69.61% (-2.94%)👎
github.com/stackitcloud/stackit-cli/internal/cmd/dns/record-set/update47.67% (ø)
github.com/stackitcloud/stackit-cli/internal/cmd/dns/zone/clone46.43% (ø)
github.com/stackitcloud/stackit-cli/internal/cmd/dns/zone/create57.14% (ø)
github.com/stackitcloud/stackit-cli/internal/cmd/dns/zone/delete24.44% (ø)
github.com/stackitcloud/stackit-cli/internal/cmd/dns/zone/describe77.05% (ø)
github.com/stackitcloud/stackit-cli/internal/cmd/dns/zone/list70.97% (-3.23%)👎
github.com/stackitcloud/stackit-cli/internal/cmd/dns/zone/update50.72% (ø)

Coverage by file

Changed files (no unit tests)

Changed FileCoverage ΔTotalCoveredMissed🤖
github.com/stackitcloud/stackit-cli/internal/cmd/dns/record-set/list/list.go69.61% (-2.94%)10271 (-3)31 (+3)👎
github.com/stackitcloud/stackit-cli/internal/cmd/dns/zone/list/list.go70.97% (-3.23%)9366 (-3)27 (+3)👎

Please note that the "Total", "Covered", and "Missed" counts above refer to code statements instead of lines of code. The value in brackets refers to the test coverage of that file in the old version of the code.

Changed unit test files

  • github.com/stackitcloud/stackit-cli/internal/cmd/dns/record-set/create/create_test.go
  • github.com/stackitcloud/stackit-cli/internal/cmd/dns/record-set/delete/delete_test.go
  • github.com/stackitcloud/stackit-cli/internal/cmd/dns/record-set/describe/describe_test.go
  • github.com/stackitcloud/stackit-cli/internal/cmd/dns/record-set/list/list_test.go
  • github.com/stackitcloud/stackit-cli/internal/cmd/dns/record-set/update/update_test.go
  • github.com/stackitcloud/stackit-cli/internal/cmd/dns/zone/clone/clone_test.go
  • github.com/stackitcloud/stackit-cli/internal/cmd/dns/zone/create/create_test.go
  • github.com/stackitcloud/stackit-cli/internal/cmd/dns/zone/delete/delete_test.go
  • github.com/stackitcloud/stackit-cli/internal/cmd/dns/zone/describe/describe_test.go
  • github.com/stackitcloud/stackit-cli/internal/cmd/dns/zone/list/list_test.go
  • github.com/stackitcloud/stackit-cli/internal/cmd/dns/zone/update/update_test.go

Sign up for freeto 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.

3 participants

@rubenhoenle@marceljk