Skip to content

Instantly share code, notes, and snippets.

@darrenderidder
Last active December 20, 2015 16:58
Show Gist options
  • Select an option

  • Save darrenderidder/6164944 to your computer and use it in GitHub Desktop.

Select an option

Save darrenderidder/6164944 to your computer and use it in GitHub Desktop.

Revisions

  1. @73rhodes 73rhodes revised this gist Aug 6, 2013. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion restmocha2.js
    Original file line number Diff line number Diff line change
    @@ -18,7 +18,7 @@ describe('app', function () {
    done();
    });

    it('should be listening at https://localhost:3333', function (done) {
    it('should be listening at localhost:3333', function (done) {
    var headers = defaultGetOptions('/');
    http.get(headers, function (res) {
    res.statusCode.should.eql(404);
  2. @73rhodes 73rhodes created this gist Aug 6, 2013.
    29 changes: 29 additions & 0 deletions restmocha2.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,29 @@
    describe('app', function () {

    before (function (done) {
    app.listen(port, function (err, result) {
    if (err) {
    done(err);
    } else {
    done();
    }
    });

    after(function (done) {
    app.close();
    });

    it('should exist', function (done) {
    should.exist(app);
    done();
    });

    it('should be listening at https://localhost:3333', function (done) {
    var headers = defaultGetOptions('/');
    http.get(headers, function (res) {
    res.statusCode.should.eql(404);
    done();
    });
    });

    });