YesPlayMusic/netease_api/app.test.js

16 lines
334 B
JavaScript
Raw Normal View History

2021-03-06 22:04:18 +08:00
const fs = require('fs')
const path = require('path')
let app
before(() => {
app = require('./app.js')
global.host = 'http://localhost:' + app.server.address().port
})
after((done) => {
app.server.close(done)
})
fs.readdirSync(path.join(__dirname, 'test')).forEach((file) => {
require(path.join(__dirname, 'test', file))
})