aboutsummaryrefslogtreecommitdiff
path: root/downloader/downloader_test.go
blob: f38e1d04a6ea8b0d83c3e3fa9cc9f192431e33f3 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
package downloader

import (
	"fmt"
	"testing"
	"time"
)

func TestGetUrl(t *testing.T) {
	u, err := getUrl("https://www.youtube.com/watch?v=_K13GJkGvDw")
	if err != nil {
		t.Fatal(err)
	}

	fmt.Println(u)
}

func TestDownload(t *testing.T) {
	if _, err := Download("https://www.youtube.com/watch?v=_K13GJkGvDw", 10*time.Second, 10*time.Second); err != nil {
		t.Fatal(err)
	}
}