forked from Shiloh/remnantchat
f006e76e80
* feat: [#21] stand up file sharing controls UI * feat: [#21] implement basic file transfer * feat: [#21] save transferred file * feat: [#21] transfer file via WebTorrent * fix: use external streamsaver assets * feat: [#21] initiate download by receiver click * fix: enable re-downloading of shared files * feat: [#21] implement sharing of multiple files * chore: enable offline development * feat: cache torrents in IndexedDB * feat: show alert when download is aborted * feat: [#21] clean up torrent data when principal offerer rescinds it * feat: clean up cached torrents on page unload * feat: show file transfer progress * fix: download files sequentially * feat: clean up file transfers when leaving the room * feat: clean up broken downloads upon leaving the page * fix: allow download animation to complete * feat: show tooltip for download button * feat: make file transfers work in browser private modes * feat: disable file share controls while creating offer
15 lines
395 B
TypeScript
15 lines
395 B
TypeScript
// jest-dom adds custom jest matchers for asserting on DOM nodes.
|
|
// allows you to do things like:
|
|
// expect(element).toHaveTextContent(/react/i)
|
|
// learn more: https://github.com/testing-library/jest-dom
|
|
import '@testing-library/jest-dom'
|
|
|
|
afterEach(() => {
|
|
jest.restoreAllMocks()
|
|
})
|
|
|
|
jest.mock('webtorrent/webtorrent.min.js', () => ({
|
|
__esModule: true,
|
|
default: class WebTorrent {},
|
|
}))
|