koa-lite/test/response/remove.js

14 lines
270 B
JavaScript
Raw Normal View History

'use strict';
const context = require('../helpers/context');
describe('ctx.remove(name)', () => {
it('should remove a field', () => {
const ctx = context();
ctx.set('x-foo', 'bar');
ctx.remove('x-foo');
ctx.response.header.should.eql({});
2015-10-12 20:36:41 +00:00
});
});