mirror of
https://github.com/fluxerapp/fluxer.git
synced 2026-09-03 05:10:25 +03:00
test(api): use a future baseline in invoice-skip premium tests (#2061)
This commit is contained in:
@@ -439,7 +439,7 @@ describe('Stripe Webhook - Invoice Events', () => {
|
||||
test('skips zero-amount subscription_update invoice without granting an extra monthly cycle', async () => {
|
||||
const account = await createTestAccount(harness);
|
||||
const subscriptionId = `sub_test_${Date.now()}`;
|
||||
const baselinePremiumUntil = new Date('2026-08-25T21:57:05.000Z');
|
||||
const baselinePremiumUntil = new Date(Date.now() + 30 * 24 * 60 * 60 * 1000);
|
||||
await createBuilder(harness, account.token)
|
||||
.post(`/test/users/${account.userId}/premium`)
|
||||
.body({
|
||||
@@ -481,7 +481,7 @@ describe('Stripe Webhook - Invoice Events', () => {
|
||||
test('skips paid subscription_update invoices so interval switches do not grant extra time', async () => {
|
||||
const account = await createTestAccount(harness);
|
||||
const subscriptionId = `sub_test_${Date.now()}`;
|
||||
const baselinePremiumUntil = new Date('2026-08-25T21:57:05.000Z');
|
||||
const baselinePremiumUntil = new Date(Date.now() + 30 * 24 * 60 * 60 * 1000);
|
||||
await createBuilder(harness, account.token)
|
||||
.post(`/test/users/${account.userId}/premium`)
|
||||
.body({
|
||||
|
||||
Reference in New Issue
Block a user