mirror of
https://github.com/halejohn/Cloudreve.git
synced 2026-01-26 09:34:57 +08:00
Test: migration modifications
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package conf
|
||||
|
||||
import (
|
||||
"github.com/HFO4/cloudreve/pkg/util"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"io/ioutil"
|
||||
"os"
|
||||
@@ -12,10 +13,12 @@ func TestInitPanic(t *testing.T) {
|
||||
asserts := assert.New(t)
|
||||
|
||||
// 日志路径不存在时
|
||||
asserts.Panics(func() {
|
||||
asserts.NotPanics(func() {
|
||||
Init("not/exist/path")
|
||||
})
|
||||
|
||||
asserts.True(util.Exists("conf.ini"))
|
||||
|
||||
}
|
||||
|
||||
// TestInitDelimiterNotFound 日志路径存在但 Key 格式错误时
|
||||
|
||||
Reference in New Issue
Block a user