cleanup debug code and last of circleci bugs

This commit is contained in:
Jonatan Nilsson 2021-10-11 02:21:20 +00:00
parent 0a2e9fdfc4
commit 799c4419dc
3 changed files with 2 additions and 16 deletions

View file

@ -17,7 +17,7 @@ jobs:
- run:
name: Run tests
command: |
npm run test:linux -- -r list
npm run test:linux
# - deploy:
# name: Push to docker
# command: |

View file

@ -20,13 +20,7 @@ app.after(function(ctx) {
let logger = ctx.log.info
if (ctx.status >= 400) {
logger = ctx.log.warn
}
console.log('')
console.log({
path: ctx.url,
status: ctx.status,
ms: Math.round(ended),
}, 'Request finished')
}
logger({
path: ctx.url,
status: ctx.status,

View file

@ -40,10 +40,6 @@ t.describe('Media (API)', () => {
assert.match(err.message, /[Tt]oken/)
assert.match(err.message, /[Mm]issing/)
await new Promise(function(res) {
setTimeout(res, 10)
})
assert.strictEqual(server.log.error.callCount, 0)
assert.strictEqual(server.log.warn.callCount, 2)
assert.strictEqual(typeof(server.log.warn.firstCall[0]), 'string')
@ -67,10 +63,6 @@ t.describe('Media (API)', () => {
assert.strictEqual(err.status, 422)
assert.match(err.message, /[Tt]oken/)
assert.match(err.message, /[Ii]nvalid/)
await new Promise(function(res) {
setTimeout(res, 10)
})
assert.strictEqual(server.log.error.callCount, 1)
assert.strictEqual(server.log.warn.callCount, 2)