test('clinic bubbleprof --version', function (t) { cli({}, ['clinic', 'bubbleprof', '--version'], function (err, stdout) { t.ifError(err) t.strictEqual( stdout, `v${require('@nearform/bubbleprof/package.json').version}\n` ) t.end() }) })
it('should print empty results with incorrect glob pattern', function (done) { if (!semver.satisfies(process.version, '>=11.7.0')) this.skip('not for node version'); exec(`${codecept_run_glob('codecept.workers-incorrect-glob.conf.js')} 1 --grep "grep" --debug`, (err, stdout, stderr) => { stdout.should.include('CodeceptJS'); // feature stdout.should.include('Running tests in 1 workers'); stdout.should.include('OK | 0 passed'); assert(!err); done(); }); });
// Otherwise set on rebuilds // NOTE: We set this pre-rebuild because post-rebuild runs after post-start because you would need to // do two rebuilds to remove the warning since appWarning is already set by the time we get here. // Running pre-rebuild ensures the warning goes away but concedes a possible warning tradeoff between // this and a build step failure app.events.on('pre-rebuild', () => { lando.cache.set(app.metaCache, updateBuiltAgainst(app, app._config.version), {persist: true}); });
function expectVersionMetrics(metrics) { expect(metrics).toHaveLength(1); expect(metrics[0].help).toEqual('Node.js version info.'); expect(metrics[0].type).toEqual('gauge'); expect(metrics[0].name).toEqual('nodejs_version_info'); expect(metrics[0].values[0].labels.version).toEqual(nodeVersion); expect(metrics[0].values[0].labels.major).toEqual(versionSegments[0]); expect(metrics[0].values[0].labels.minor).toEqual(versionSegments[1]); expect(metrics[0].values[0].labels.patch).toEqual(versionSegments[2]); }
(function main() { const version = require('./package.json').version; let preload = fs.readFileSync('./lib/preload/ndb/preload.js', 'utf8'); preload = preload.replace(/process\.versions\['ndb'\] = '[\d+\.]+';/, `process.versions['ndb'] = '${version}';`); fs.writeFileSync('./lib/preload/ndb/preload.js', preload, 'utf8'); })();
describeMongoDatabases(tests) { mongoDatabases.forEach((mongoDatabase) => { // eslint-disable-next-line jest/valid-describe describe(`using Mongo Database v${mongoDatabase.version}`, tests(mongoDatabase.url)); }); }
test('version.satisfies', t => { t.true(version('2.15.8').satisfies('>=2.15.8 <3.0.0 || >=3.10.1')); t.true(version('2.99.8').satisfies('>=2.15.8 <3.0.0 || >=3.10.1')); t.true(version('3.10.1').satisfies('>=2.15.8 <3.0.0 || >=3.10.1')); t.true(version('6.7.0-next.0').satisfies('<6.8.0')); t.false(version('3.0.0').satisfies('>=2.15.8 <3.0.0 || >=3.10.1')); t.false(version('3.10.0').satisfies('>=2.15.8 <3.0.0 || >=3.10.1')); });
/* * Helper to parse generic solr config */ const parseElse = options => { options.image = `solr:${options.version}`; // Custom config dir command if (_.has(options, 'config.dir')) options.command = `${options.command} ${options.config.dir}`; return options; }
let releaseCommit = async function() { let {v} = argv; if(['major', 'minor', 'patch'].indexOf(v) === -1) { v = 'patch'; } Config.version = semver.inc(Config.version, v); let newConfig = JSON.stringify(Config, null, 2); // update package.json writeFileSync('package.json', newConfig); await spawn('git', ['commit', '-m', `Release v${Config.version}`, 'package.json']); await spawn('git', ['push']); }
const getClientInfo = () => { return { type: "nodejs", version: MOLECULER_VERSION, langVersion: process.version }; }
test('clinic bubbleprof -v', function (t) { cli({}, ['clinic', 'bubbleprof', '-v'], function (err, stdout) { t.ifError(err) t.strictEqual( stdout, `v${require('@nearform/bubbleprof/package.json').version}\n` ) t.end() }) })
test('clinic --version', function (t) { cli({}, ['clinic', '--version'], function (err, stdout) { t.ifError(err) t.strictEqual( stdout, `v${require('../package.json').version}\n` ) t.end() }) })
test('clinic doctor -v', function (t) { cli({}, ['clinic', 'doctor', '-v'], function (err, stdout) { t.ifError(err) t.strictEqual( stdout, `v${require('@nearform/doctor/package.json').version}\n` ) t.end() }) })