2.0.12 • Published 7 months ago

@substrate-system/webtorrent-fixtures v2.0.12

Weekly downloads
-
License
MIT
Repository
github
Last release
7 months ago

webtorrent-fixtures

tests module install size license

Sample torrent files for the WebTorrent test suite

Torrent and content test files. All files are Public Domain or Creative Commons.

install

npm i -S @substrate-system/webtorrent-fixtures

Usage

import fixtures from '@substrate-system/webtorrent-fixtures'
console.log(fixtures.leaves)

Inline

If you need to bundle your test files, use the inline version. Buffers are exposed as base64 strings.

import fixtures from '@substrate-system/webtorrent-fixtures/inline'

revive

To parse the JSON string, use the revive function. This will convert all base64 string to Buffer objects.

import base64Fixtures, { 
    revive
} from '@substrate-system/webtorrent-fixtures/inline'

const torrent = revive(base64Fixtures.leaves.parsedTorrent)

License

MIT. Copyright (c) Feross Aboukhadijeh and WebTorrent, LLC.

2.0.12

7 months ago

2.0.11

7 months ago

2.0.10

7 months ago

2.0.9

7 months ago

2.0.8

7 months ago

2.0.7

7 months ago

2.0.4

7 months ago

2.0.2

7 months ago