0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-03 23:00:14 -05:00

Reset URL service between test boots

refs https://github.com/TryGhost/Toolbox/issues/592

- we should reset the URL service to avoid event listeners piling up and
  slowing down CI due to the number of events it has to process
This commit is contained in:
Daniel Lockyer 2023-06-13 12:33:47 +02:00 committed by Daniel Lockyer
parent cedfb14924
commit 264773ccd1

View file

@ -73,6 +73,9 @@ const startGhost = async (options = {}) => {
// Adapter cache has to be cleared to avoid reusing cached adapter instances between restarts
adapterManager.clearCache();
// Reset the URL service so we clear out all the listeners
urlServiceUtils.resetGenerators();
const defaults = {
backend: true,
frontend: false,