New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

test-agent

Package Overview
Dependencies
Maintainers
1
Versions
108
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

test-agent - npm Package Compare versions

Comparing version 0.7.2 to 0.8.0

python/.npmignore

4

HISTORY.md

@@ -0,1 +1,5 @@

# 0.7.3
- fixed a bug where numerious extra sockets where opened.
- added python client hack v1
# 0.7.2

@@ -2,0 +6,0 @@ - console.log will now be grouped with its environment when available.

2

lib/node/server/runner-growl.js

@@ -52,3 +52,3 @@ /**

if (stats.failures) {
var msg = stats.failures + ' of ' + runner.total + ' tests failed';
var msg = stats.failures + ' of ' + runner.tests + ' tests failed';
notify(msg, { title: 'Failed', image: images.fail });

@@ -55,0 +55,0 @@ } else {

@@ -70,6 +70,7 @@ (function(window) {

if(this.reporter) {
return MochaDriver.createMutliReporter(
TestAgent.Mocha.JsonStreamReporter,
box.mocha.reporters[this.reporter]
box.Mocha.reporters[this.reporter]
);

@@ -79,2 +80,4 @@ } else {

}
return result;
},

@@ -91,2 +94,11 @@

box.require(this.mochaUrl, function onRequireMocha() {
if (!box.process) {
box.process = {
stdout: {
write: console.log
},
write: console.log
};
}
//setup mocha

@@ -93,0 +105,0 @@ box.mocha.setup({

@@ -141,3 +141,4 @@ (function(window) {

'state',
'type'
'type',
'slow'
];

@@ -144,0 +145,0 @@

@@ -42,18 +42,16 @@ /*(The MIT License)

function Base(runner) {
var self = this,
stats,
failures = this.failures = [];
var self = this
, stats = this.stats = { suites: 0, tests: 0, passes: 0, pending: 0, failures: 0 }
, failures = this.failures = [];
stats = this.stats = {
suites: 0, tests: 0, passes: 0, pending: 0, failures: 0
};
if (!runner) return;
this.runner = runner;
runner.on('start', function onStart() {
runner.stats = stats;
runner.on('start', function(){
stats.start = new Date;
});
runner.on('suite', function onSuite(suite) {
runner.on('suite', function(suite){
stats.suites = stats.suites || 0;

@@ -63,3 +61,3 @@ suite.root || stats.suites++;

runner.on('test end', function onTestEnd(test) {
runner.on('test end', function(test){
stats.tests = stats.tests || 0;

@@ -69,11 +67,11 @@ stats.tests++;

runner.on('pass', function onPass(test) {
runner.on('pass', function(test){
stats.passes = stats.passes || 0;
var medium = Base.slow / 2;
//reformatted for gjslint
test.speed =
(test.duration > Base.slow) ?
'slow' : test.duration > medium ?
'medium' : 'fast';
var medium = test.slow() / 2;
test.speed = test.duration > test.slow()
? 'slow'
: test.duration > medium
? 'medium'
: 'fast';

@@ -83,3 +81,3 @@ stats.passes++;

runner.on('fail', function onFail(test, err) {
runner.on('fail', function(test, err){
stats.failures = stats.failures || 0;

@@ -91,3 +89,3 @@ stats.failures++;

runner.on('end', function onEnd() {
runner.on('end', function(){
stats.end = new Date;

@@ -97,3 +95,3 @@ stats.duration = new Date - stats.start;

runner.on('pending', function onPending() {
runner.on('pending', function(){
stats.pending++;

@@ -100,0 +98,0 @@ });

@@ -41,3 +41,3 @@ (function() {

} else {
Mocha = window.mocha;
Mocha = window.Mocha;
}

@@ -44,0 +44,0 @@

@@ -56,10 +56,17 @@ (function() {

RunnerStreamProxy.Test = function Test(test) {
this.__test__ = test;
copy.call(this, test, ['fullTitle']);
copy.call(this, test, ['fullTitle', 'slow']);
wrapWithEnvId(this);
};
RunnerStreamProxy.Test.prototype.fullTitle = function() {
return this.__test__.fullTitle;
RunnerStreamProxy.Test.prototype = {
fullTitle: function() {
return this.__test__.fullTitle;
},
slow: function() {
return this.__test__.slow;
}
};

@@ -66,0 +73,0 @@

@@ -88,2 +88,7 @@ //depends on TestAgent.Responder

if (this.socket && this.socket.readyState < 2) {
// don't open a socket is one is already open.
return;
}
if (this.retry && this.retries >= this.retryLimit) {

@@ -90,0 +95,0 @@ throw new Client.RetryError(

{
"name": "test-agent",
"version": "0.7.2",
"version": "0.8.0",
"author": "James Lal",

@@ -29,3 +29,2 @@ "description": "execute client side tests from browser report back to cli",

"websocket.io": "~0.1.0",
"mocha": "~1.0",
"growl": "*",

@@ -39,3 +38,4 @@ "optimist": "~0.3",

"devDependencies": {
"expect.js": "~0.1"
"expect.js": "~0.1",
"mocha": "~1.7"
},

@@ -42,0 +42,0 @@

@@ -7,2 +7,10 @@ # Test Agent

## Compatibility:
This project is largely designed to help us test gaia (Firefox OS
frontend). Documentation will come soon but see the test-agent folder
for now.
Works with mocha ~1.7
More soon...

@@ -7,4 +7,17 @@ (function(window) {

var config = {
host: window.location.hostname,
port: window.location.port
};
var queryString = window.location.search.slice(1);
queryString.split('&').forEach(function(pair) {
var data = pair.split('=');
var key = data[0];
var value = data[1];
config[key] = value;
});
worker.use(TestAgent.BrowserWorker.Websocket, {
url: 'ws://' + window.location.host
url: 'ws://' + config.host + ':' + config.port
});

@@ -42,3 +55,3 @@

'sandbox': function() {
worker.loader.require('/vendor/expect.js');
worker.loader.require('/node_modules/expect.js/expect.js');
},

@@ -45,0 +58,0 @@

@@ -12,3 +12,3 @@ (function(window) {

worker.use(TestAgent.BrowserWorker.MochaDriver, {
mochaUrl: '/vendor/mocha/mocha.js',
mochaUrl: '/node_modules/mocha/mocha.js',
testHelperUrl: '/test/helper.js',

@@ -24,3 +24,3 @@ //don't need a reporter for proxy

'sandbox': function() {
worker.loader.require('/vendor/expect.js');
worker.loader.require('/node_modules/expect.js/expect.js');
},

@@ -27,0 +27,0 @@

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

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