1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-11-23 10:30:04 +01:00
metamask-extension/test/integration/index.js

24 lines
518 B
JavaScript
Raw Normal View History

var fs = require('fs')
var path = require('path')
2017-05-04 23:35:10 +02:00
var browserify = require('browserify')
var tests = fs.readdirSync(path.join(__dirname, 'lib'))
var bundlePath = path.join(__dirname, 'bundle.js')
2017-05-04 23:35:10 +02:00
var b = browserify()
// Remove old bundle
try {
fs.unlinkSync(bundlePath)
2017-06-22 15:46:03 +02:00
var writeStream = fs.createWriteStream(bundlePath)
2017-06-22 15:46:03 +02:00
tests.forEach(function (fileName) {
b.add(path.join(__dirname, 'lib', fileName))
})
2017-06-22 15:46:03 +02:00
b.bundle().pipe(writeStream)
} catch (e) {
console.error('Integration build failure', e)
}