aboutsummaryrefslogtreecommitdiff
path: root/main_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'main_test.go')
-rw-r--r--main_test.go10
1 files changed, 10 insertions, 0 deletions
diff --git a/main_test.go b/main_test.go
index 819f9d0..702146f 100644
--- a/main_test.go
+++ b/main_test.go
@@ -125,3 +125,13 @@ func helperCleanupFile(t *testing.T, name string) {
t.Fatal(err)
}
}
+
+func TestEpisodeURLPrefix(t *testing.T) {
+ url := "http://www.radiorus.ru/brand/57083/episodes"
+ got := episodeURLPrefix(url)
+ want := "http://www.radiorus.ru/brand/"
+
+ if got != want {
+ t.Fatal(fmt.Sprintf("got %v, want %v", got, want))
+ }
+}