fix: Only check free tier limits if billing is enabled #69
ci.yml
on: push
Test Suite
4m 21s
Lint & Type Check
2m 17s
Annotations
6 errors and 4 warnings
|
Test Suite
Process completed with exit code 1.
|
|
apps/api/src/services/__tests__/BillingLimitService.test.ts > BillingLimitService - Critical Enforcement > Free Tier Total Limit (1000 emails/month across all types) > should show shared limit for all categories in getLimitsAndUsage for free tier:
apps/api/src/services/__tests__/BillingLimitService.test.ts#L748
AssertionError: expected null to be 1000 // Object.is equality
- Expected:
1000
+ Received:
null
❯ apps/api/src/services/__tests__/BillingLimitService.test.ts:748:38
|
|
apps/api/src/services/__tests__/BillingLimitService.test.ts > BillingLimitService - Critical Enforcement > Free Tier Total Limit (1000 emails/month across all types) > should allow free tier to send different distribution of email types:
apps/api/src/services/__tests__/BillingLimitService.test.ts#L649
AssertionError: expected +0 to be 999 // Object.is equality
- Expected
+ Received
- 999
+ 0
❯ apps/api/src/services/__tests__/BillingLimitService.test.ts:649:35
|
|
apps/api/src/services/__tests__/BillingLimitService.test.ts > BillingLimitService - Critical Enforcement > Free Tier Total Limit (1000 emails/month across all types) > should show warning at 80% of free tier total limit (800 emails):
apps/api/src/services/__tests__/BillingLimitService.test.ts#L601
AssertionError: expected false to be true // Object.is equality
- Expected
+ Received
- true
+ false
❯ apps/api/src/services/__tests__/BillingLimitService.test.ts:601:37
|
|
apps/api/src/services/__tests__/BillingLimitService.test.ts > BillingLimitService - Critical Enforcement > Free Tier Total Limit (1000 emails/month across all types) > should count all email types towards free tier total limit:
apps/api/src/services/__tests__/BillingLimitService.test.ts#L545
AssertionError: expected +0 to be 600 // Object.is equality
- Expected
+ Received
- 600
+ 0
❯ apps/api/src/services/__tests__/BillingLimitService.test.ts:545:35
|
|
apps/api/src/services/__tests__/BillingLimitService.test.ts > BillingLimitService - Critical Enforcement > Free Tier Total Limit (1000 emails/month across all types) > should enforce 1000 email total limit for free tier projects:
apps/api/src/services/__tests__/BillingLimitService.test.ts#L477
AssertionError: promise resolved "{ …(29) }" instead of rejecting
- Expected
+ Received
- Error {
- "message": "rejected promise",
+ {
+ "attachments": null,
+ "body": "Test",
+ "bouncedAt": null,
+ "campaignId": null,
+ "clickedAt": null,
+ "clicks": 0,
+ "complainedAt": null,
+ "contactId": "0b0f9241-885c-48e5-b5fa-d34b04bf5555",
+ "createdAt": 2025-12-09T13:29:12.529Z,
+ "deliveredAt": null,
+ "error": null,
+ "from": "test@example.com",
+ "fromName": null,
+ "headers": null,
+ "id": "c07812f7-f8c4-40db-ae1a-7a91301e773c",
+ "messageId": null,
+ "openedAt": null,
+ "opens": 0,
+ "projectId": "a3ca9e01-37b0-4250-b3ce-930f4c84db06",
+ "replyTo": null,
+ "sentAt": null,
+ "sourceType": "WORKFLOW",
+ "status": "PENDING",
+ "subject": "Test",
+ "templateId": null,
+ "toName": null,
+ "updatedAt": 2025-12-09T13:29:12.529Z,
+ "workflowExecutionId": null,
+ "workflowStepExecutionId": null,
}
❯ apps/api/src/services/__tests__/BillingLimitService.test.ts:477:7
|
|
Lint & Type Check:
apps/web/src/components/BillingLimits.tsx#L53
'error' is defined but never used
|
|
Lint & Type Check:
apps/web/src/components/BillingLimits.tsx#L1
'useCallback' is defined but never used
|
|
Lint & Type Check:
apps/api/src/controllers/Users.ts#L466
Unexpected any. Specify a different type
|
|
Test Suite
No files were found with the provided path: coverage/
**/*.test.ts.log. No artifacts will be uploaded.
|