Sha256: f0a8272b29a2c3114356a6ce1e16e8ea62b75e62ef4e13642be77b727f6da948

Contents?: true

Size: 675 Bytes

Versions: 76

Compression:

Stored size: 675 Bytes

Contents

var test = require('tape');
var parse = require('../').parse;

test('set env vars', function (t) {
    t.same(
        parse('ABC=444 x y z'),
        [ 'ABC=444', 'x', 'y', 'z' ]
    );
    t.same(
        parse('ABC=3\\ 4\\ 5 x y z'),
        [ 'ABC=3 4 5', 'x', 'y', 'z' ]
    );
    t.same(
        parse('X="7 8 9" printx'),
        [ 'X=7 8 9', 'printx' ]
    );
    t.same(
        parse('X="7 8 9"; printx'),
        [ 'X=7 8 9', { op: ';' }, 'printx' ]
    );
    t.same(
        parse('X="7 8 9"; printx', function (key) {
            t.fail('should not have matched any keys');
        }),
        [ 'X=7 8 9', { op: ';' }, 'printx' ]
    );
    
    t.end();
});

Version data entries

76 entries across 76 versions & 4 rubygems

Version Path
trusty-festivity-extension-2.6.3 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.6.2 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.6.1 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.6 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.5.19 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.5.18 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.5.17 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.5.16 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.5.15 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.5.14 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.5.13 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.5.12 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.5.11 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.5.10 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.5.9 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.5.8 node_modules/bower/node_modules/shell-quote/test/set.js
trusty-festivity-extension-2.5.7 node_modules/bower/node_modules/shell-quote/test/set.js
minimum_viable_product-0.0.11 test/dummy/node_modules/shell-quote/test/set.js
brwy_rails-0.0.6 test/dummy/node_modules/shell-quote/test/set.js
brwy_rails-0.0.5 test/dummy/node_modules/shell-quote/test/set.js