2020-01-09 04:45:14 -05:00
|
|
|
const fs = require('fs');
|
|
|
|
const path = require('path');
|
|
|
|
|
2020-01-09 06:40:04 -05:00
|
|
|
const testsDir = path.join(__dirname, 'tests');
|
2020-01-09 04:45:14 -05:00
|
|
|
module.exports = fs.readdirSync(testsDir).map(name => ({
|
|
|
|
name,
|
2020-01-10 02:30:49 -05:00
|
|
|
contentAsString: fs.readFileSync(path.join(testsDir, name), 'utf8'),
|
|
|
|
contentAsBuffer: fs.readFileSync(path.join(testsDir, name)),
|
2020-01-09 06:40:04 -05:00
|
|
|
})).sort((a, b) => a.name.localeCompare(b.name));
|