Delete userWorkspace when removed from workspace (#13131)

Fixes https://github.com/twentyhq/twenty/issues/13024
This commit is contained in:
Charles Bochet
2025-07-09 18:34:50 +02:00
committed by GitHub
parent eba997be98
commit 7e419337b5
71 changed files with 377 additions and 436 deletions

View File

@ -19,7 +19,7 @@ describe('BillingController (integration)', () => {
await client
.post('/webhooks/stripe')
.set('Authorization', `Bearer ${ADMIN_ACCESS_TOKEN}`)
.set('Authorization', `Bearer ${APPLE_JANE_ADMIN_ACCESS_TOKEN}`)
.set('stripe-signature', 'correct-signature')
.set('Content-Type', 'application/json')
.send(JSON.stringify(productUpdatedPayload))
@ -30,7 +30,7 @@ describe('BillingController (integration)', () => {
await client
.post('/webhooks/stripe')
.set('Authorization', `Bearer ${ADMIN_ACCESS_TOKEN}`)
.set('Authorization', `Bearer ${APPLE_JANE_ADMIN_ACCESS_TOKEN}`)
.set('stripe-signature', 'correct-signature')
.set('Content-Type', 'application/json')
.send(JSON.stringify(priceCreatedPayload))
@ -52,7 +52,7 @@ describe('BillingController (integration)', () => {
await client
.post('/webhooks/stripe')
.set('Authorization', `Bearer ${ADMIN_ACCESS_TOKEN}`)
.set('Authorization', `Bearer ${APPLE_JANE_ADMIN_ACCESS_TOKEN}`)
.set('stripe-signature', 'correct-signature')
.set('Content-Type', 'application/json')
.send(JSON.stringify(subscriptionCreatedPayload))
@ -64,7 +64,7 @@ describe('BillingController (integration)', () => {
await client
.post('/webhooks/stripe')
.set('Authorization', `Bearer ${ADMIN_ACCESS_TOKEN}`)
.set('Authorization', `Bearer ${APPLE_JANE_ADMIN_ACCESS_TOKEN}`)
.set('stripe-signature', 'correct-signature')
.set('Content-Type', 'application/json')
.send(JSON.stringify(entitlementUpdatedPayload))
@ -84,7 +84,7 @@ describe('BillingController (integration)', () => {
await client
.post('/webhooks/stripe')
.set('Authorization', `Bearer ${ADMIN_ACCESS_TOKEN}`)
.set('Authorization', `Bearer ${APPLE_JANE_ADMIN_ACCESS_TOKEN}`)
.set('stripe-signature', 'correct-signature')
.set('Content-Type', 'application/json')
.send(JSON.stringify(entitlementUpdatedPayload))
@ -103,7 +103,7 @@ describe('BillingController (integration)', () => {
await client
.post('/webhooks/stripe')
.set('Authorization', `Bearer ${ADMIN_ACCESS_TOKEN}`)
.set('Authorization', `Bearer ${APPLE_JANE_ADMIN_ACCESS_TOKEN}`)
.set('stripe-signature', 'invalid-signature')
.set('Content-Type', 'application/json')
.send(JSON.stringify(entitlementUpdatedPayload))