Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/webtorrent/webtorrent.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorFeross Aboukhadijeh <feross@feross.org>2016-02-10 09:04:12 +0300
committerFeross Aboukhadijeh <feross@feross.org>2016-02-10 09:44:08 +0300
commitf251050f6cb96f622c390b7ebc49ca007ed8c0e1 (patch)
tree4d9701d0afd5e4d8b4d35f086d4f41bd3683fefb /test
parentffe6892906331c8e7f1568d4175430fa1680387f (diff)
partially fix stream test; add missing /announce
Diffstat (limited to 'test')
-rw-r--r--test/stream.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/test/stream.js b/test/stream.js
index 8294593..713f682 100644
--- a/test/stream.js
+++ b/test/stream.js
@@ -11,7 +11,10 @@ test('client.seed: stream', function (t) {
var tracker = new Tracker()
var seeder, client
tracker.listen(function () {
- announce.push('http://localhost:' + tracker.http.address().port)
+ var port = tracker.http.address().port
+ t.pass('tracker listening on ' + port)
+ announce.push('http://localhost:' + port + '/announce')
+
seeder = new WebTorrent({ dht: false })
client = new WebTorrent({ dht: false })
@@ -46,7 +49,6 @@ test('client.seed: stream', function (t) {
var copts = { announce: announce }
seeder.seed([stream], sopts, function (torrent) {
console.log(torrent.magnetURI)
- // this works: client.add(torrent, copts, function (dl) {
client.add(torrent.magnetURI, copts, function (dl) {
t.equal(dl.files.length, 1)
t.equal(dl.files[0].name, 'hello.txt')