From 2c4a0b5d909bd7eefeb582001babce816fdfab03 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 15 Mar 2016 13:16:54 +0100 Subject: Fix tests --- client/angular/videos/components/watch/videos-watch.component.ts | 3 ++- client/package.json | 1 + package.json | 1 + server/tests/api/utils.js | 2 +- 4 files changed, 5 insertions(+), 2 deletions(-) diff --git a/client/angular/videos/components/watch/videos-watch.component.ts b/client/angular/videos/components/watch/videos-watch.component.ts index da7f942db..1a17e2b1a 100644 --- a/client/angular/videos/components/watch/videos-watch.component.ts +++ b/client/angular/videos/components/watch/videos-watch.component.ts @@ -39,8 +39,9 @@ export class VideosWatchComponent implements OnInit, CanDeactivate { loadVideo(video: Video) { this.video = video; - + console.log('Adding ' + this.video.magnetUri + '.'); this.client.add(this.video.magnetUri, (torrent) => { + console.log('Added ' + this.video.magnetUri + '.'); torrent.files[0].appendTo(this._elementRef.nativeElement, (err) => { if (err) { alert('Cannot append the file.'); diff --git a/client/package.json b/client/package.json index 78abde752..dbb065974 100644 --- a/client/package.json +++ b/client/package.json @@ -30,6 +30,7 @@ "reflect-metadata": "0.1.2", "rxjs": "5.0.0-beta.2", "systemjs": "0.19.22", + "webtorrent": "^0.85.1", "zone.js": "0.5.15" }, "devDependencies": { diff --git a/package.json b/package.json index 383e6165c..1b83f5eca 100644 --- a/package.json +++ b/package.json @@ -41,6 +41,7 @@ "async": "^1.2.1", "bittorrent-tracker": "^7.0.0", "body-parser": "^1.12.4", + "concurrently": "^2.0.0", "config": "^1.14.0", "connect-livereload": "^0.5.3", "debug": "^2.2.0", diff --git a/server/tests/api/utils.js b/server/tests/api/utils.js index c70696571..60c3c8d4e 100644 --- a/server/tests/api/utils.js +++ b/server/tests/api/utils.js @@ -176,7 +176,7 @@ function uploadVideo (url, name, description, fixture, end) { .field('name', name) .field('description', description) .attach('input_video', pathUtils.join(__dirname, 'fixtures', fixture)) - .expect(201) + .expect(204) .end(end) } -- cgit v1.2.3