1
0
cucumber-js-demo/async/features/support/hooks.js

19 lines
292 B
JavaScript

import { BeforeAll, AfterAll } from '@cucumber/cucumber'
import express from 'express'
let server
BeforeAll(function () {
const app = express()
app.get('/', (req, res) => {
res.send('Alea iacta est')
})
server = app.listen(8080)
})
AfterAll(function () {
server.close()
})