mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-03-11 02:12:21 -05:00
Added cache invalidation to the POST authentication/setup route
issue https://github.com/TryGhost/Team/issues/859
This commit is contained in:
parent
50eddaa208
commit
9c2cfb5d00
4 changed files with 8 additions and 0 deletions
|
@ -20,6 +20,9 @@ module.exports = {
|
|||
setup: {
|
||||
statusCode: 201,
|
||||
permissions: false,
|
||||
headers: {
|
||||
cacheInvalidate: true
|
||||
},
|
||||
validation: {
|
||||
docName: 'setup'
|
||||
},
|
||||
|
|
|
@ -13,6 +13,9 @@ module.exports = {
|
|||
setup: {
|
||||
statusCode: 201,
|
||||
permissions: false,
|
||||
headers: {
|
||||
cacheInvalidate: true
|
||||
},
|
||||
validation: {
|
||||
docName: 'setup'
|
||||
},
|
||||
|
|
|
@ -61,6 +61,7 @@ describe('Authentication API v3', function () {
|
|||
const jsonResponse = res.body;
|
||||
should.exist(jsonResponse.users);
|
||||
should.not.exist(jsonResponse.meta);
|
||||
should.exist(res.headers['x-cache-invalidate']);
|
||||
|
||||
jsonResponse.users.should.have.length(1);
|
||||
localUtils.API.checkResponse(jsonResponse.users[0], 'user');
|
||||
|
|
|
@ -61,6 +61,7 @@ describe('Authentication API v3', function () {
|
|||
const jsonResponse = res.body;
|
||||
should.exist(jsonResponse.users);
|
||||
should.not.exist(jsonResponse.meta);
|
||||
should.exist(res.headers['x-cache-invalidate']);
|
||||
|
||||
jsonResponse.users.should.have.length(1);
|
||||
localUtils.API.checkResponse(jsonResponse.users[0], 'user');
|
||||
|
|
Loading…
Add table
Reference in a new issue