git ssb

0+

cel-desktop / ssb-pkg



Tree: ca90b5ca0579ebdcc0635288bce4978e3fb200f5

Files: ca90b5ca0579ebdcc0635288bce4978e3fb200f5 / test / test-50-extensions / main.js

696 bytesRaw
1#!/usr/bin/env node
2
3/* eslint-disable strict */
4
5'use strict';
6
7const path = require('path');
8const assert = require('assert');
9const utils = require('../utils.js');
10
11assert(!module.parent);
12assert(__dirname === process.cwd());
13
14const target = process.argv[2] || 'host';
15const input = './test-x-index.js';
16const output = './test-output.exe';
17
18let left, right;
19
20left = utils.spawn.sync(
21 'node', [ path.basename(input) ],
22 { cwd: path.dirname(input) }
23);
24
25utils.pkg.sync([
26 '--public',
27 '--target', target,
28 '--output', output, input
29]);
30
31right = utils.spawn.sync(
32 './' + path.basename(output), [],
33 { cwd: path.dirname(output) }
34);
35
36assert.equal(left, right);
37utils.vacuum.sync(output);
38

Built with git-ssb-web