mirror of
https://github.com/microsoft/TypeScript-Node-Starter.git
synced 2025-11-08 20:27:37 +00:00
this seems a bit crude but allows running the tests and having them take care of setting up the port to use
11 lines
243 B
TypeScript
11 lines
243 B
TypeScript
import * as supertest from "supertest";
|
|
const app = require("../src/app");
|
|
const request = supertest(app);
|
|
|
|
describe("GET /contact", () => {
|
|
it("should return 200 OK", () => {
|
|
return request.get("/contact")
|
|
.expect(200);
|
|
});
|
|
});
|