New configuration system

This commit is contained in:
Deluan
2016-03-30 00:05:57 -04:00
parent 9049d97820
commit c2b1f9782b
14 changed files with 101 additions and 41 deletions
+6
View File
@@ -0,0 +1,6 @@
DisableValidation = false
User = "deluan"
Password = "wordpass"
DbPath = "/tmp/testDb"
MusicFolder = "./tests/itunes-library.xml"
DownsampleCommand = "ffmpeg -i %s -b:a %bk mp3 -"
+2
View File
@@ -7,10 +7,12 @@ import (
"testing"
"github.com/astaxie/beego"
"github.com/deluan/gosonic/conf"
"github.com/deluan/gosonic/utils"
)
func Init(t *testing.T, skipOnShort bool) {
conf.LoadFromFile("../tests/gosonic-test.toml")
if skipOnShort && testing.Short() {
t.Skip("skipping test in short mode.")
}