Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@travetto/test

Package Overview
Dependencies
Maintainers
1
Versions
352
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@travetto/test - npm Package Compare versions

Comparing version 0.0.6 to 0.0.7

2

package.json

@@ -28,3 +28,3 @@ {

},
"version": "0.0.6"
"version": "0.0.7"
}
import * as os from 'os';
import { Agent } from './agent';
import { Shutdown } from '@travetto/base';

@@ -19,2 +20,3 @@ export class AgentPool {

}
Shutdown.onShutdown(this.constructor.__id, () => this.shutdown());
}

@@ -65,3 +67,3 @@

} else {
let agent = await Promise.race(Array.from(this.pendingAgents.values()).map(x => x.completion));
let agent = await Promise.race(Array.from(this.pendingAgents).map(x => x.completion));
this.returnAgent(agent);

@@ -71,13 +73,21 @@ }

await Promise.all(Array.from(this.pendingAgents.values()).map(x => x.completion));
await Promise.all(Array.from(this.pendingAgents).map(x => x.completion));
}
shutdown() {
for (let agent of this.pendingAgents) {
for (let agent of Array.from(this.pendingAgents)) {
this.returnAgent(agent);
}
for (let agent of this.availableAgents) {
agent.process.kill('SIGKILL');
for (let agent of Array.from(this.availableAgents)) {
if (agent.process) {
try {
console.debug('Killing Process', agent.id)
agent.process.kill('SIGKILL');
} catch (e) {
console.error('Error', agent.id, e);
}
}
}
}
}
}

@@ -65,3 +65,2 @@ import * as minimist from 'minimist';

let files = await TestUtil.getTests(globs);
let agentPool = new AgentPool(require.resolve('../../bin/worker.js'));

@@ -74,2 +73,4 @@ for (let l of listeners) {

let agentPool = new AgentPool(require.resolve('../../bin/worker.js'));
await agentPool.process(files, async (file, run, agent) => {

@@ -76,0 +77,0 @@ if (agent) {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc