Fix for _PushStatus Stuck 'running' when Count is Off (#4319)

* Fix for _PushStatus stuck 'running' if count is off

* use 'count' for batches

* push worker test fix
This commit is contained in:
Benjamin Wilson Friedman
2017-11-05 10:04:46 -08:00
committed by Florent Vilmart
parent 842343a1a9
commit c1a7347143
5 changed files with 276 additions and 9 deletions

View File

@@ -276,7 +276,7 @@ describe('PushWorker', () => {
'failedPerType.ios': { __op: 'Increment', amount: 1 },
[`sentPerUTCOffset.${UTCOffset}`]: { __op: 'Increment', amount: 1 },
[`failedPerUTCOffset.${UTCOffset}`]: { __op: 'Increment', amount: 1 },
count: { __op: 'Increment', amount: -2 },
count: { __op: 'Increment', amount: -1 }
});
const query = new Parse.Query('_PushStatus');
return query.get(handler.objectId, { useMasterKey: true });
@@ -354,7 +354,7 @@ describe('PushWorker', () => {
'failedPerType.ios': { __op: 'Increment', amount: 1 },
[`sentPerUTCOffset.${UTCOffset}`]: { __op: 'Increment', amount: 1 },
[`failedPerUTCOffset.${UTCOffset}`]: { __op: 'Increment', amount: 1 },
count: { __op: 'Increment', amount: -2 },
count: { __op: 'Increment', amount: -1 }
});
done();
});