2020-06-23 17:30:03 +00:00
|
|
|
/* eslint-disable
|
|
|
|
no-unused-vars,
|
|
|
|
*/
|
|
|
|
// TODO: This file was created by bulk-decaffeinate.
|
|
|
|
// Fix any style issues and re-enable lint.
|
2020-06-23 17:30:16 +00:00
|
|
|
let MockClient
|
|
|
|
const sinon = require('sinon')
|
2014-11-14 15:30:18 +00:00
|
|
|
|
2020-06-23 17:30:16 +00:00
|
|
|
let idCounter = 0
|
2014-11-14 15:30:18 +00:00
|
|
|
|
2020-06-23 17:30:16 +00:00
|
|
|
module.exports = MockClient = class MockClient {
|
|
|
|
constructor() {
|
|
|
|
this.ol_context = {}
|
|
|
|
this.join = sinon.stub()
|
|
|
|
this.emit = sinon.stub()
|
|
|
|
this.disconnect = sinon.stub()
|
|
|
|
this.id = idCounter++
|
|
|
|
this.publicId = idCounter++
|
2020-07-13 09:42:50 +00:00
|
|
|
this.joinLeaveEpoch = 0
|
2020-06-23 17:30:16 +00:00
|
|
|
}
|
2020-06-23 17:30:03 +00:00
|
|
|
|
2020-06-23 17:30:16 +00:00
|
|
|
disconnect() {}
|
|
|
|
}
|