Skip to content

Instantly share code, notes, and snippets.

@adammcarth
Created November 13, 2015 09:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save adammcarth/5490b7cb77fc2c1eae42 to your computer and use it in GitHub Desktop.
Save adammcarth/5490b7cb77fc2c1eae42 to your computer and use it in GitHub Desktop.
module.exports = function(server) {
var request = require("supertest");
it("[GET] /", function(done) {
request(server).get("/").expect(200, done);
});
it("[GET] /posts", function(done) {
request(server).get("/posts").expect(200, done);
});
}
// Runs the my-app testing suite
var require = require("really-need");
describe("Running all My App tests:", function() {
var server;
beforeEach(function () {
server = require("../server/server.js", { bustCache: true });
});
afterEach(function (done) {
server.close(done);
});
describe("Check that all public routes are responding...", require("route_tests.js")(server));
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment