From fb739a68121e82e1999c3f2f8ea9797dd1ee4c2c Mon Sep 17 00:00:00 2001 From: Dhi Aurrahman Date: Sat, 6 May 2017 19:21:10 +0700 Subject: [PATCH] Add more test --- test.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/test.js b/test.js index aa4151b..729733b 100644 --- a/test.js +++ b/test.js @@ -38,3 +38,16 @@ test('ok', function (t) { server.close() }) }) + +test('ok', function (t) { + listen() + .then(function ({port}) { + return request(`http://localhost:${port}`) + }) + .then(function ({statusCode, body}) { + t.equal(statusCode, 200) + t.equal(body, 'OK') + t.end() + server.close() + }) +})