Updated API framework debug and test names
- these tests have moved from `core/` so the names are no longer relevant
This commit is contained in:
parent
687e68d5de
commit
348924d431
@ -1,4 +1,4 @@
|
||||
const debug = require('@tryghost/debug')('api:shared:frame');
|
||||
const debug = require('@tryghost/debug')('frame');
|
||||
const _ = require('lodash');
|
||||
|
||||
/**
|
||||
|
@ -1,5 +1,5 @@
|
||||
const url = require('url');
|
||||
const debug = require('@tryghost/debug')('api:shared:headers');
|
||||
const debug = require('@tryghost/debug')('headers');
|
||||
const Promise = require('bluebird');
|
||||
const INVALIDATE_ALL = '/*';
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
const url = require('url');
|
||||
const debug = require('@tryghost/debug')('api:shared:http');
|
||||
const debug = require('@tryghost/debug')('http');
|
||||
|
||||
const Frame = require('./frame');
|
||||
const headers = require('./headers');
|
||||
|
@ -1,4 +1,4 @@
|
||||
const debug = require('@tryghost/debug')('api:shared:pipeline');
|
||||
const debug = require('@tryghost/debug')('pipeline');
|
||||
const Promise = require('bluebird');
|
||||
const _ = require('lodash');
|
||||
const errors = require('@tryghost/errors');
|
||||
|
@ -1,4 +1,4 @@
|
||||
const debug = require('@tryghost/debug')('api:shared:serializers:handle');
|
||||
const debug = require('@tryghost/debug')('serializers:handle');
|
||||
const Promise = require('bluebird');
|
||||
const {sequence} = require('@tryghost/promise');
|
||||
const errors = require('@tryghost/errors');
|
||||
|
@ -1,4 +1,4 @@
|
||||
const debug = require('@tryghost/debug')('api:shared:serializers:input:all');
|
||||
const debug = require('@tryghost/debug')('serializers:input:all');
|
||||
const _ = require('lodash');
|
||||
const utils = require('../../utils');
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
const debug = require('@tryghost/debug')('api:shared:validators:handle');
|
||||
const debug = require('@tryghost/debug')('validators:handle');
|
||||
const Promise = require('bluebird');
|
||||
const errors = require('@tryghost/errors');
|
||||
const {sequence} = require('@tryghost/promise');
|
||||
|
@ -1,4 +1,4 @@
|
||||
const debug = require('@tryghost/debug')('api:shared:validators:input:all');
|
||||
const debug = require('@tryghost/debug')('validators:input:all');
|
||||
const _ = require('lodash');
|
||||
const Promise = require('bluebird');
|
||||
const tpl = require('@tryghost/tpl');
|
||||
|
@ -1,7 +1,7 @@
|
||||
const should = require('should');
|
||||
const shared = require('../');
|
||||
|
||||
describe('Unit: api/shared/frame', function () {
|
||||
describe('Frame', function () {
|
||||
it('constructor', function () {
|
||||
const frame = new shared.Frame();
|
||||
Object.keys(frame).should.eql([
|
||||
|
@ -1,6 +1,6 @@
|
||||
const shared = require('../');
|
||||
|
||||
describe('Unit: api/shared/headers', function () {
|
||||
describe('Headers', function () {
|
||||
it('empty headers config', function () {
|
||||
return shared.headers.get().then((result) => {
|
||||
result.should.eql({});
|
||||
|
@ -2,7 +2,7 @@ const should = require('should');
|
||||
const sinon = require('sinon');
|
||||
const shared = require('../');
|
||||
|
||||
describe('Unit: api/shared/http', function () {
|
||||
describe('HTTP', function () {
|
||||
let req;
|
||||
let res;
|
||||
let next;
|
||||
|
@ -3,7 +3,7 @@ const should = require('should');
|
||||
const sinon = require('sinon');
|
||||
const shared = require('../');
|
||||
|
||||
describe('Unit: api/shared/pipeline', function () {
|
||||
describe('Pipeline', function () {
|
||||
afterEach(function () {
|
||||
sinon.restore();
|
||||
});
|
||||
|
@ -3,7 +3,7 @@ const Promise = require('bluebird');
|
||||
const sinon = require('sinon');
|
||||
const shared = require('../../');
|
||||
|
||||
describe('Unit: api/shared/serializers/handle', function () {
|
||||
describe('serializers/handle', function () {
|
||||
afterEach(function () {
|
||||
sinon.restore();
|
||||
});
|
||||
|
@ -1,7 +1,7 @@
|
||||
const should = require('should');
|
||||
const shared = require('../../../');
|
||||
|
||||
describe('Unit: utils/serializers/input/all', function () {
|
||||
describe('serializers/input/all', function () {
|
||||
describe('all', function () {
|
||||
it('transforms into model readable format', function () {
|
||||
const apiConfig = {};
|
||||
|
@ -1,6 +1,6 @@
|
||||
const optionsUtil = require('../../lib/utils/options');
|
||||
|
||||
describe('Unit: api/shared/util/options', function () {
|
||||
describe('util/options', function () {
|
||||
it('returns an array with empty string when no parameters are passed', function () {
|
||||
optionsUtil.trimAndLowerCase().should.eql(['']);
|
||||
});
|
||||
|
@ -3,7 +3,7 @@ const Promise = require('bluebird');
|
||||
const sinon = require('sinon');
|
||||
const shared = require('../../');
|
||||
|
||||
describe('Unit: api/shared/validators/handle', function () {
|
||||
describe('validators/handle', function () {
|
||||
afterEach(function () {
|
||||
sinon.restore();
|
||||
});
|
||||
|
@ -4,7 +4,7 @@ const sinon = require('sinon');
|
||||
const Promise = require('bluebird');
|
||||
const shared = require('../../../');
|
||||
|
||||
describe('Unit: api/shared/validators/input/all', function () {
|
||||
describe('validators/input/all', function () {
|
||||
afterEach(function () {
|
||||
sinon.restore();
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user