Sha256: 406c67ee8558c456c7a8f0c0d0ccd2c292cabf0cc52c777576665a2c99392b05
Contents?: true
Size: 695 Bytes
Versions: 7
Compression:
Stored size: 695 Bytes
Contents
var test = require('tape'); var mdeps = require('module-deps'); var bpack = require('browser-pack'); var insert = require('../'); var concat = require('concat-stream'); var vm = require('vm'); test('early return', function (t) { t.plan(4); var s = mdeps() s.pipe(bpack({ raw: true })).pipe(concat(function (src) { var c = { t: t, setTimeout: setTimeout, clearTimeout: clearTimeout }; vm.runInNewContext(src, c); })); s.write({ transform: inserter, global: true }); s.end(__dirname + '/return/main.js'); }); function inserter (file) { return insert(file, { basedir: __dirname + '/return' }); }
Version data entries
7 entries across 7 versions & 2 rubygems