sse.js 310 B

1234567891011121314
  1. class SSEClientTransport {
  2. constructor(url, options = {}) {
  3. this.url = url
  4. this.options = options
  5. this.onerror = null
  6. this.connect = jest.fn().mockResolvedValue()
  7. this.close = jest.fn().mockResolvedValue()
  8. this.start = jest.fn().mockResolvedValue()
  9. }
  10. }
  11. module.exports = {
  12. SSEClientTransport,
  13. }