Add additional supertest tests for /signup, /api, /contact and /login
parent
c8ecb086f9
commit
85b5d93678
35
test/app.js
35
test/app.js
|
@ -9,11 +9,42 @@ describe('GET /', function() {
|
|||
});
|
||||
});
|
||||
|
||||
describe('GET /reset', function() {
|
||||
describe('GET /login', function() {
|
||||
it('should return 200 OK', function(done) {
|
||||
request(app)
|
||||
.get('/login')
|
||||
.expect(200, done);
|
||||
});
|
||||
});
|
||||
|
||||
describe('GET /signup', function() {
|
||||
it('should return 200 OK', function(done) {
|
||||
request(app)
|
||||
.get('/signup')
|
||||
.expect(200, done);
|
||||
});
|
||||
});
|
||||
|
||||
describe('GET /api', function() {
|
||||
it('should return 200 OK', function(done) {
|
||||
request(app)
|
||||
.get('/api')
|
||||
.expect(200, done);
|
||||
});
|
||||
});
|
||||
|
||||
describe('GET /contact', function() {
|
||||
it('should return 200 OK', function(done) {
|
||||
request(app)
|
||||
.get('/contact')
|
||||
.expect(200, done);
|
||||
});
|
||||
});
|
||||
|
||||
describe('GET /random-url', function() {
|
||||
it('should return 404', function(done) {
|
||||
request(app)
|
||||
.get('/reset')
|
||||
.expect(404, done);
|
||||
// this will fail
|
||||
});
|
||||
});
|
Loading…
Reference in New Issue