YTSFlix_Go/youtube/youtube_test.go
2018-11-04 15:58:15 +01:00

20 lines
378 B
Go

package youtube
import (
"fmt"
"github.com/stretchr/testify/assert"
"testing"
)
func TestGet(t *testing.T) {
u, err := Get("https://www.youtube.com/watch?v=1rZ-JorHJEY")
assert.NoError(t, err)
assert.NotEmpty(t, u)
fmt.Println(u)
}
func TestDownload(t *testing.T) {
err := Download("https://www.youtube.com/watch?v=1rZ-JorHJEY", "test.mp4")
assert.NoError(t, err)
}