const uuid = require('uuid'); const client = require('../src/client'); function delay(ms) { return new Promise(function (resolve, reject) { setTimeout(resolve, ms); }) } function delayOnlyFirst(count, action) { if (count === 0) return action(); return delay(200) .then(function () { action(); }) } module.exports = { 'Test Subscribe To Stream Happy Path': function(test) { const resolveLinkTos = false; const numberOfPublishedEvents = 5; test.expect(numberOfPublishedEvents + 6); var publishedEvents = []; for(var i=0;i