Cleaned up some e2e/integration tests

- e2e tests are tests that cover critical functionality by booting ghost
- integration tests are more like unit tests, but need to initialise and use a db
- so settings shouldn't start Ghost, url service is critical and should be in integration, and preview is critical and should be in e2e
This commit is contained in:
Hannah Wolfe 2021-10-06 14:40:39 +01:00
parent 726db1c0ec
commit e4074286df
No known key found for this signature in database
GPG Key ID: 9F8C7532D0A6BA55
3 changed files with 8 additions and 8 deletions

View File

@ -7,8 +7,8 @@ const should = require('should');
const sinon = require('sinon');
const supertest = require('supertest');
const cheerio = require('cheerio');
const testUtils = require('../../utils');
const config = require('../../../core/shared/config');
const testUtils = require('../utils');
const config = require('../../core/shared/config');
const ghost = testUtils.startGhost;
let request;

View File

@ -12,7 +12,7 @@ const testUtils = require('../../utils');
describe('Settings', function () {
before(function () {
return testUtils.startGhost();
return testUtils.setup();
});
// Allowlist: Only this list needs updating when a core setting is added/removed/renamed

View File

@ -2,11 +2,11 @@ const _ = require('lodash');
const should = require('should');
const sinon = require('sinon');
const rewire = require('rewire');
const testUtils = require('../../utils');
const configUtils = require('../../utils/configUtils');
const models = require('../../../core/server/models');
const events = require('../../../core/server/lib/common/events');
const UrlService = rewire('../../../core/frontend/services/url/UrlService');
const testUtils = require('../utils');
const configUtils = require('../utils/configUtils');
const models = require('../../core/server/models');
const events = require('../../core/server/lib/common/events');
const UrlService = rewire('../../core/frontend/services/url/UrlService');
/**
* @NOTE