[monorepo] clean up per-project queue migration (#35573)

GitOrigin-RevId: 988df4cdc7d929efc921e7e99d803c6ce6e52c57
This commit is contained in:
Jakob Ackermann
2026-09-17 11:31:52 +00:00
committed by Copybot
parent d8f167dec2
commit 68352783b0
27 changed files with 195 additions and 1528 deletions
@@ -305,7 +305,6 @@ describe('EditorHttpController', function () {
isRestrictedUser: false,
isTokenMember: false,
isInvitedMember: true,
usePerProjectPendingUpdates: false,
})
})
@@ -363,7 +362,6 @@ describe('EditorHttpController', function () {
isRestrictedUser: true,
isTokenMember: false,
isInvitedMember: false,
usePerProjectPendingUpdates: false,
})
})
})
@@ -420,14 +418,8 @@ describe('EditorHttpController', function () {
isRestrictedUser: true,
isTokenMember: false,
isInvitedMember: false,
usePerProjectPendingUpdates: false,
})
})
it('should not fetch a split test assignment', function (ctx) {
expect(ctx.SplitTestHandler.promises.featureFlagEnabledForUser).not.to
.have.been.called
})
})
describe('with a token access user', function () {
@@ -460,36 +452,10 @@ describe('EditorHttpController', function () {
isRestrictedUser: false,
isTokenMember: true,
isInvitedMember: false,
usePerProjectPendingUpdates: false,
})
})
})
describe('with the per-project-pending-updates flag enabled', function () {
beforeEach(async function (ctx) {
ctx.SplitTestHandler.promises.featureFlagEnabledForUser.resolves(true)
await new Promise(resolve => {
ctx.res.callback = resolve
ctx.EditorHttpController.joinProject(ctx.req, ctx.res)
})
})
it('should fetch the assignment for the joining user', function (ctx) {
expect(
ctx.SplitTestHandler.promises.featureFlagEnabledForUser
).to.have.been.calledWith(
ctx.user._id.toString(),
'per-project-pending-updates'
)
})
it('should return usePerProjectPendingUpdates=true', function (ctx) {
expect(ctx.res.json).toHaveBeenCalledWith(
expect.objectContaining({ usePerProjectPendingUpdates: true })
)
})
})
describe('when project is not found', function () {
beforeEach(async function (ctx) {
ctx.ProjectGetter.promises.getProject.resolves(null)