mirror of
https://github.com/TeaOSLab/EdgeAPI.git
synced 2025-11-19 04:10:28 +08:00
自动检测本地数据库磁盘是否已满,如果已满,则不再写入访问日志
This commit is contained in:
14
internal/db/utils/disk_test.go
Normal file
14
internal/db/utils/disk_test.go
Normal file
@@ -0,0 +1,14 @@
|
||||
// Copyright 2022 Liuxiangchao iwind.liu@gmail.com. All rights reserved. Official site: https://goedge.cn .
|
||||
|
||||
package dbutils_test
|
||||
|
||||
import (
|
||||
dbutils "github.com/TeaOSLab/EdgeAPI/internal/db/utils"
|
||||
_ "github.com/iwind/TeaGo/bootstrap"
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestHasFreeSpace(t *testing.T) {
|
||||
t.Log(dbutils.CheckHasFreeSpace())
|
||||
t.Log(dbutils.LocalDatabaseDataDir)
|
||||
}
|
||||
Reference in New Issue
Block a user