Skip to content

Commit 9058333

Browse files
crdantclaude
andcommitted
test: use getter methods for license fields in install config tests
Updates test assertions to use GetLicenseID() and GetAppSlug() getter methods instead of directly accessing license.Spec fields. This aligns test code with production patterns and ensures tests work correctly with both v1beta1 and v1beta2 license formats. Changes: - Line 649: license.Spec.LicenseID -> license.GetLicenseID() - Line 650: license.Spec.AppSlug -> license.GetAppSlug() This completes Phase 3 of the license v1beta2 support work, ensuring test code follows the same defensive patterns as production code. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
1 parent 19bdeda commit 9058333

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

cmd/installer/cli/install_config_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -646,8 +646,8 @@ spec:
646646
if tt.expectLicense {
647647
assert.NotEmpty(t, installCfg.licenseBytes, "License bytes should be populated")
648648
assert.NotNil(t, installCfg.license, "License should be parsed")
649-
assert.Equal(t, "test-license-id", installCfg.license.Spec.LicenseID)
650-
assert.Equal(t, "test-app", installCfg.license.Spec.AppSlug)
649+
assert.Equal(t, "test-license-id", installCfg.license.GetLicenseID())
650+
assert.Equal(t, "test-app", installCfg.license.GetAppSlug())
651651
} else {
652652
assert.Empty(t, installCfg.licenseBytes, "License bytes should be empty")
653653
assert.Nil(t, installCfg.license, "License should be nil")

0 commit comments

Comments
 (0)