Files
photoprism/internal/service/cluster/instance/instance_test.go
2025-09-25 17:52:44 +02:00

20 lines
347 B
Go

package instance
import (
"os"
"testing"
"github.com/photoprism/photoprism/pkg/fs"
)
// TestMain ensures SQLite test DB artifacts are purged after the suite runs.
func TestMain(m *testing.M) {
// Run unit tests.
code := m.Run()
// Remove temporary SQLite files after running the tests.
fs.PurgeTestDbFiles(".", false)
os.Exit(code)
}