mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-09 21:17:15 +03:00
Added testing
This commit is contained in:
12
src/config.js
Normal file
12
src/config.js
Normal file
@@ -0,0 +1,12 @@
|
||||
|
||||
var fs = require('fs');
|
||||
var config = undefined;
|
||||
|
||||
// Check to see if launched in test mode
|
||||
if (process.env.npm_lifecycle_script === 'node test.js') {
|
||||
config = JSON.parse(fs.readFileSync('test.json'));
|
||||
} else {
|
||||
config = JSON.parse(fs.readFileSync('config.json'));
|
||||
}
|
||||
|
||||
module.exports = config;
|
||||
Reference in New Issue
Block a user