This repository has been archived on 2019-06-23. You can view files and clone it, but cannot push or open issues or pull requests.
mumbledj/bot/playlist_test.go

49 lines
928 B
Go
Raw Normal View History

2016-06-21 02:16:05 +02:00
/*
* MumbleDJ
* By Matthieu Grieger
* bot/playlist_test.go
* Copyright (c) 2016 Matthieu Grieger (MIT License)
*/
package bot
import (
"testing"
"github.com/stretchr/testify/suite"
)
type PlaylistTestSuite struct {
Playlist Playlist
suite.Suite
}
func (suite *PlaylistTestSuite) SetupTest() {
suite.Playlist = Playlist{
ID: "id",
Title: "title",
Submitter: "submitter",
Service: "service",
}
}
func (suite *PlaylistTestSuite) TestGetID() {
suite.Equal("id", suite.Playlist.GetID())
}
func (suite *PlaylistTestSuite) TestGetTitle() {
suite.Equal("title", suite.Playlist.GetTitle())
}
func (suite *PlaylistTestSuite) TestGetSubmitter() {
suite.Equal("submitter", suite.Playlist.GetSubmitter())
}
func (suite *PlaylistTestSuite) TestGetService() {
suite.Equal("service", suite.Playlist.GetService())
}
func TestPlaylistTestSuite(t *testing.T) {
suite.Run(t, new(PlaylistTestSuite))
}