Open TimNZ opened 3 months ago
https://github.com/alexfernandez/loadtest/blob/a0f4b30a4d4d44a2699b9d50625ba727e85d277f/lib/pool.js#L75
finishRequest(client, result, error) { if (this.options.statusCallback) { result.requestIndex = this.requestIndex++ result.instanceIndex = this.loadTest.instanceIndex this.options.statusCallback(error, result);
In my case 'error' is 'Connection error: connect ECONNREFUSED 127.0.0.1:3007', and result is null, resulting in 'TypeError: Cannot set properties of undefined (setting 'requestIndex')' on setting result.requestIndex
Hi @TimNZ , sorry for the delay. Good catch, care to send a patch?
https://github.com/alexfernandez/loadtest/blob/a0f4b30a4d4d44a2699b9d50625ba727e85d277f/lib/pool.js#L75
In my case 'error' is 'Connection error: connect ECONNREFUSED 127.0.0.1:3007', and result is null, resulting in 'TypeError: Cannot set properties of undefined (setting 'requestIndex')' on setting result.requestIndex