Removed force start from themes test
refs https://github.com/TryGhost/Toolbox/issues/135 - Looking closer into the reason why the test was failing without "forceStart" revealed that the server only start was overoptimized - "initServicesForFrontend" should be a part of a backend as those are generic theme services.
This commit is contained in:
parent
8d1863e54b
commit
9c77abebb5
@ -368,9 +368,9 @@ async function bootGhost({backend = true, frontend = true} = {}) {
|
||||
// Step 4 - Load Ghost with all its services
|
||||
debug('Begin: Load Ghost Services & Apps');
|
||||
await initCore({ghostServer, config, bootLogger, frontend});
|
||||
await initServicesForFrontend();
|
||||
|
||||
if (frontend) {
|
||||
await initServicesForFrontend();
|
||||
await initFrontend();
|
||||
}
|
||||
const ghostApp = await initExpressApps({frontend, backend});
|
||||
|
@ -29,10 +29,7 @@ describe('Themes API', function () {
|
||||
// NOTE: this flag should not be here! the URL service re-initialization should be fixed instead
|
||||
// The reason why this init doesn't work without "forceStart" is because during the "restartModeGhostStart"
|
||||
// the routing.routerManager is never called with "start". That's why a full boot is needed
|
||||
await localUtils.startGhost({
|
||||
forceStart: true,
|
||||
frontend: true
|
||||
});
|
||||
await localUtils.startGhost();
|
||||
ownerRequest = supertest.agent(config.get('url'));
|
||||
await localUtils.doAuth(ownerRequest);
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user