mirror of
https://github.com/phishingclub/phishingclub.git
synced 2026-12-06 01:53:42 +01:00
20 lines
468 B
Go
20 lines
468 B
Go
package service
|
|
|
|
import (
|
|
"os"
|
|
"testing"
|
|
|
|
"github.com/phishingclub/phishingclub/repository"
|
|
"github.com/phishingclub/phishingclub/testdb"
|
|
)
|
|
|
|
// TestMain turns off the pause between chunked writes. It lets other writers
|
|
// take their turn in production, but the service tests have no other writers
|
|
// and would spend most of their time waiting.
|
|
func TestMain(m *testing.M) {
|
|
repository.WriteChunkPause = 0
|
|
code := m.Run()
|
|
testdb.DropTemplates()
|
|
os.Exit(code)
|
|
}
|