diff options
author | Julien Dessaux | 2023-01-01 23:23:57 +0100 |
---|---|---|
committer | Julien Dessaux | 2023-01-02 20:26:28 +0100 |
commit | 3acf783d948ebb1907da875ef87b0da9ef2309ff (patch) | |
tree | 06b805fab10e638a9f5e66714ef4a29b6409c1e7 /main.js | |
parent | Refactored game creation (diff) | |
download | jeux-de-mots-3acf783d948ebb1907da875ef87b0da9ef2309ff.tar.gz jeux-de-mots-3acf783d948ebb1907da875ef87b0da9ef2309ff.tar.bz2 jeux-de-mots-3acf783d948ebb1907da875ef87b0da9ef2309ff.zip |
Began adding tests
Diffstat (limited to '')
-rw-r--r-- | main.js | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -15,5 +15,9 @@ app.use("/games", gamesRouter); app.use("/static", express.static("static")); app.use("/", rootRouter); -const port = process.env.PORT || 3000; -app.listen(port, () => console.log(`listening on port ${port}`)); +if (process.env.NODE_ENV !== "test") { + const port = process.env.PORT || 3000; + app.listen(port, () => console.log(`listening on port ${port}`)); +} + +export default app; |