Skip to content

Commit 9435add

Browse files
smoghe-bwclaude
andcommitted
Address PR review comments: add Object.values assertions and endpoint-event test
- Add Object.values() assertions to all 37 enum tests to catch future changes - Add missing endpoint-event.test.ts with proper date assertions Generated from Claude9 with Claude Code Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 568b2a5 commit 9435add

38 files changed

Lines changed: 62 additions & 0 deletions

tests/unit/models/business-entity-type-enum.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,6 @@ describe('BusinessEntityTypeEnum', () => {
77
expect(BusinessEntityTypeEnum.PublicProfit).toBe('PUBLIC_PROFIT');
88
expect(BusinessEntityTypeEnum.NonProfit).toBe('NON_PROFIT');
99
expect(BusinessEntityTypeEnum.Government).toBe('GOVERNMENT');
10+
expect(Object.values(BusinessEntityTypeEnum)).toEqual(['SOLE_PROPRIETOR', 'PRIVATE_PROFIT', 'PUBLIC_PROFIT', 'NON_PROFIT', 'GOVERNMENT']);
1011
});
1112
});

tests/unit/models/business-registration-issuing-country-enum.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,6 @@ describe('BusinessRegistrationIssuingCountryEnum', () => {
1919
expect(BusinessRegistrationIssuingCountryEnum.Ind).toBe('IND');
2020
expect(BusinessRegistrationIssuingCountryEnum.Chn).toBe('CHN');
2121
expect(BusinessRegistrationIssuingCountryEnum.Bgr).toBe('BGR');
22+
expect(Object.values(BusinessRegistrationIssuingCountryEnum)).toEqual(['USA', 'CAN', 'HKG', 'GBR', 'IRL', 'BRA', 'NLD', 'AUS', 'FRA', 'NZL', 'DEU', 'ESP', 'CHE', 'CYP', 'IND', 'CHN', 'BGR']);
2223
});
2324
});

tests/unit/models/business-registration-type-enum.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,5 +20,6 @@ describe('BusinessRegistrationTypeEnum', () => {
2020
expect(BusinessRegistrationTypeEnum.Cnpj).toBe('CNPJ');
2121
expect(BusinessRegistrationTypeEnum.Uid).toBe('UID');
2222
expect(BusinessRegistrationTypeEnum.Other).toBe('OTHER');
23+
expect(Object.values(BusinessRegistrationTypeEnum)).toEqual(['EIN', 'CBN', 'NEQ', 'PROVINCIAL_NUMBER', 'CRN', 'VAT', 'ACN', 'ABN', 'BRN', 'SIREN', 'SIRET', 'NZBN', 'UST_IDNR', 'CIF', 'NIF', 'CNPJ', 'UID', 'OTHER']);
2324
});
2425
});

tests/unit/models/call-direction-enum.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,6 @@ describe('CallDirectionEnum', () => {
44
test('should define the expected values', () => {
55
expect(CallDirectionEnum.Inbound).toBe('inbound');
66
expect(CallDirectionEnum.Outbound).toBe('outbound');
7+
expect(Object.values(CallDirectionEnum)).toEqual(['inbound', 'outbound']);
78
});
89
});

tests/unit/models/call-state-enum.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,6 @@ describe('CallStateEnum', () => {
44
test('should define the expected values', () => {
55
expect(CallStateEnum.Active).toBe('active');
66
expect(CallStateEnum.Completed).toBe('completed');
7+
expect(Object.values(CallStateEnum)).toEqual(['active', 'completed']);
78
});
89
});

tests/unit/models/call-transcription-detected-language-enum.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,6 @@ describe('CallTranscriptionTrackEnum', () => {
55
expect(CallTranscriptionDetectedLanguageEnum.EnUs).toBe('en-US');
66
expect(CallTranscriptionDetectedLanguageEnum.EsUs).toBe('es-US');
77
expect(CallTranscriptionDetectedLanguageEnum.FrFr).toBe('fr-FR');
8+
expect(Object.values(CallTranscriptionDetectedLanguageEnum)).toEqual(['en-US', 'es-US', 'fr-FR']);
89
});
910
});

tests/unit/models/call-transcription-track-enum.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,6 @@ describe('CallTranscriptionTrackEnum', () => {
44
test('should define the expected values', () => {
55
expect(CallTranscriptionTrackEnum.Inbound).toBe('inbound');
66
expect(CallTranscriptionTrackEnum.Outbound).toBe('outbound');
7+
expect(Object.values(CallTranscriptionTrackEnum)).toEqual(['inbound', 'outbound']);
78
});
89
});

tests/unit/models/callback-method-enum.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,6 @@ describe('CallbackMethodEnum', () => {
44
test('should define the expected values', () => {
55
expect(CallbackMethodEnum.Get).toBe('GET');
66
expect(CallbackMethodEnum.Post).toBe('POST');
7+
expect(Object.values(CallbackMethodEnum)).toEqual(['GET', 'POST']);
78
});
89
});

tests/unit/models/card-width-enum.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,6 @@ describe('CardWidthEnum', () => {
44
test('should define the expected values', () => {
55
expect(CardWidthEnum.Small).toBe('SMALL');
66
expect(CardWidthEnum.Medium).toBe('MEDIUM');
7+
expect(Object.values(CardWidthEnum)).toEqual(['SMALL', 'MEDIUM']);
78
});
89
});

tests/unit/models/completed-lookup-status-enum.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,6 @@ describe('CompletedLookupStatusEnum', () => {
55
expect(CompletedLookupStatusEnum.Complete).toBe('COMPLETE');
66
expect(CompletedLookupStatusEnum.PartialComplete).toBe('PARTIAL_COMPLETE');
77
expect(CompletedLookupStatusEnum.Failed).toBe('FAILED');
8+
expect(Object.values(CompletedLookupStatusEnum)).toEqual(['COMPLETE', 'PARTIAL_COMPLETE', 'FAILED']);
89
});
910
});

0 commit comments

Comments
 (0)