2012-04-26 04:57:28 -07:00
|
|
|
|
|
|
|
|
var app = require('../../examples/error')
|
2014-03-05 22:06:14 -08:00
|
|
|
, request = require('supertest');
|
2011-12-18 17:27:13 +01:00
|
|
|
|
|
|
|
|
describe('error', function(){
|
|
|
|
|
describe('GET /', function(){
|
|
|
|
|
it('should respond with 500', function(done){
|
|
|
|
|
request(app)
|
|
|
|
|
.get('/')
|
|
|
|
|
.expect(500,done)
|
|
|
|
|
})
|
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
describe('GET /next', function(){
|
|
|
|
|
it('should respond with 500', function(done){
|
|
|
|
|
request(app)
|
|
|
|
|
.get('/next')
|
|
|
|
|
.expect(500,done)
|
|
|
|
|
})
|
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
describe('GET /missing', function(){
|
|
|
|
|
it('should respond with 404', function(done){
|
|
|
|
|
request(app)
|
|
|
|
|
.get('/missing')
|
|
|
|
|
.expect(404,done)
|
|
|
|
|
})
|
|
|
|
|
})
|
2017-08-05 23:37:39 -04:00
|
|
|
})
|