forked from XiovV/Golty
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathyoutube-dl_test.go
33 lines (32 loc) · 981 Bytes
/
youtube-dl_test.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
package main
//
//var targets1 = []DownloadTarget{
// {
// URL: "https://www.youtube.com/user/NewRetroWave/",
// },
// {
// URL: "https://www.youtube.com/user/HungOverGargoyle",
// },
//}
//
//func TestGetMetadata(t *testing.T) {
// assert := assert.New(t)
// for _, target := range targets1 {
// targetMetadata, err := target.GetMetadata()
// assert.Nil(err)
// if target.URL == "https://www.youtube.com/user/NewRetroWave/" {
// assert.Equal("NewRetroWave", targetMetadata.Uploader)
// } else if target.URL == "https://www.youtube.com/user/HungOverGargoyle" {
// assert.Equal("Electronic Gems", targetMetadata.Uploader)
// }
// }
//}
//
//func TestDownloadTarget_GetLatestVideo(t *testing.T) {
// assert := assert.New(t)
// for _, target := range targets1 {
// latestVideoId, err := target.GetLatestVideo()
// assert.Nil(err)
// assert.Equal(11, len(latestVideoId), "length of latestVideoId should be 11 because that's how long video id's are on youtube")
// }
//}