24 lines
413 B
Go
24 lines
413 B
Go
|
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
||
|
|
||
|
package fan
|
||
|
|
||
|
import (
|
||
|
"testing"
|
||
|
"os"
|
||
|
"log"
|
||
|
)
|
||
|
|
||
|
var TempDir string
|
||
|
|
||
|
func TestMain(m *testing.M) {
|
||
|
var err error
|
||
|
TempDir, err = os.MkdirTemp("", "testfan")
|
||
|
if err != nil || TempDir == "" {
|
||
|
log.Fatal(err)
|
||
|
}
|
||
|
//folio.DocumentRegistry.ResourceTypes = resource.ResourceTypes
|
||
|
rc := m.Run()
|
||
|
os.RemoveAll(TempDir)
|
||
|
os.Exit(rc)
|
||
|
}
|