Browse Source

[web] update pricing settings for Nov 2025 update (#29947)

* update pricing settings for Nov 2025 update
* update `StripeLookupKeyVersion` type
* update unit tests to match new Stripe version

GitOrigin-RevId: f5df5167b605b6667cc19edad09fb2c0f72a293b
Kristina 8 months ago
parent
commit
4a9b66627e

+ 2 - 1
services/web/app/src/Features/Subscription/PlansLocator.mjs

@@ -55,7 +55,8 @@ const recurlyCodeToStripeBaseLookupKey = {
   'assistant-annual': 'assistant_annual',
 }
 
-const LATEST_STRIPE_LOOKUP_KEY_VERSION = 'jun2025'
+// Keep in sync with StripeLookupKeyVersion in types/subscription/plan.ts
+const LATEST_STRIPE_LOOKUP_KEY_VERSION = 'nov2025'
 
 /**
  * Build the Stripe lookup key, will be in this format:

File diff suppressed because it is too large
+ 180 - 180
services/web/app/templates/plans/groups.json


+ 11 - 11
services/web/test/unit/src/Subscription/PlansLocator.test.mjs

@@ -57,7 +57,7 @@ describe('PlansLocator', function () {
         planCode,
         currency
       )
-      expect(lookupKey).to.equal('standard_monthly_jun2025_eur')
+      expect(lookupKey).to.equal('standard_monthly_nov2025_eur')
     })
 
     it('should map "collaborator_free_trial_7_days" plan code to stripe lookup keys', function (ctx) {
@@ -67,7 +67,7 @@ describe('PlansLocator', function () {
         planCode,
         currency
       )
-      expect(lookupKey).to.equal('standard_monthly_jun2025_eur')
+      expect(lookupKey).to.equal('standard_monthly_nov2025_eur')
     })
 
     it('should map "collaborator-annual" plan code to stripe lookup keys', function (ctx) {
@@ -77,7 +77,7 @@ describe('PlansLocator', function () {
         planCode,
         currency
       )
-      expect(lookupKey).to.equal('standard_annual_jun2025_eur')
+      expect(lookupKey).to.equal('standard_annual_nov2025_eur')
     })
 
     it('should map "professional" plan code to stripe lookup keys', function (ctx) {
@@ -87,7 +87,7 @@ describe('PlansLocator', function () {
         planCode,
         currency
       )
-      expect(lookupKey).to.equal('professional_monthly_jun2025_eur')
+      expect(lookupKey).to.equal('professional_monthly_nov2025_eur')
     })
 
     it('should map "professional_free_trial_7_days" plan code to stripe lookup keys', function (ctx) {
@@ -97,7 +97,7 @@ describe('PlansLocator', function () {
         planCode,
         currency
       )
-      expect(lookupKey).to.equal('professional_monthly_jun2025_eur')
+      expect(lookupKey).to.equal('professional_monthly_nov2025_eur')
     })
 
     it('should map "professional-annual" plan code to stripe lookup keys', function (ctx) {
@@ -107,7 +107,7 @@ describe('PlansLocator', function () {
         planCode,
         currency
       )
-      expect(lookupKey).to.equal('professional_annual_jun2025_eur')
+      expect(lookupKey).to.equal('professional_annual_nov2025_eur')
     })
 
     it('should map "student" plan code to stripe lookup keys', function (ctx) {
@@ -117,7 +117,7 @@ describe('PlansLocator', function () {
         planCode,
         currency
       )
-      expect(lookupKey).to.equal('student_monthly_jun2025_eur')
+      expect(lookupKey).to.equal('student_monthly_nov2025_eur')
     })
 
     it('shoult map "student_free_trial_7_days" plan code to stripe lookup keys', function (ctx) {
@@ -127,7 +127,7 @@ describe('PlansLocator', function () {
         planCode,
         currency
       )
-      expect(lookupKey).to.equal('student_monthly_jun2025_eur')
+      expect(lookupKey).to.equal('student_monthly_nov2025_eur')
     })
 
     it('should map "student-annual" plan code to stripe lookup keys', function (ctx) {
@@ -137,7 +137,7 @@ describe('PlansLocator', function () {
         planCode,
         currency
       )
-      expect(lookupKey).to.equal('student_annual_jun2025_eur')
+      expect(lookupKey).to.equal('student_annual_nov2025_eur')
     })
 
     it('should return null for unknown add-on codes', function (ctx) {
@@ -169,7 +169,7 @@ describe('PlansLocator', function () {
         currency,
         billingCycleInterval
       )
-      expect(lookupKey).to.equal('assistant_monthly_jun2025_gbp')
+      expect(lookupKey).to.equal('assistant_monthly_nov2025_gbp')
     })
 
     it('returns the key for an annual AI assist add-on', function (ctx) {
@@ -181,7 +181,7 @@ describe('PlansLocator', function () {
         currency,
         billingCycleInterval
       )
-      expect(lookupKey).to.equal('assistant_annual_jun2025_gbp')
+      expect(lookupKey).to.equal('assistant_annual_nov2025_gbp')
     })
   })
 

+ 2 - 1
services/web/types/subscription/plan.ts

@@ -108,7 +108,8 @@ export type StripeBaseLookupKey =
   | 'group_standard_educational'
   | 'group_professional_educational'
 
-export type StripeLookupKeyVersion = 'jun2025'
+// Keep in sync with LATEST_STRIPE_LOOKUP_KEY_VERSION in PlansLocator.mjs
+export type StripeLookupKeyVersion = 'nov2025'
 
 export type StripeLookupKey =
   `${StripeBaseLookupKey}_${StripeLookupKeyVersion}_${StripeCurrencyCode}`

Some files were not shown because too many files changed in this diff