1
0
Fork 0
mirror of https://github.com/FrankerFaceZ/FrankerFaceZ.git synced 2025-08-12 00:50:53 +00:00

Add comments, add dumpStackOnCtrlZ() for tests

This commit is contained in:
Kane York 2015-12-23 21:56:56 -08:00
parent 18c1abd3e3
commit 89ff64f52c
9 changed files with 42 additions and 5 deletions

View file

@ -9,6 +9,7 @@ import (
"net/http/httptest"
"net/url"
"os"
"sync"
"testing"
"time"
)
@ -20,7 +21,13 @@ const (
)
const SetupNoServers = 0
var signalCatch sync.Once
func TSetup(flags int, backendChecker *TBackendRequestChecker) (socketserver *httptest.Server, backend *httptest.Server, urls TURLs) {
signalCatch.Do(func() {
go dumpStackOnCtrlZ()
})
DumpBacklogData()
ioutil.WriteFile("index.html", []byte(`
@ -36,7 +43,7 @@ func TSetup(flags int, backendChecker *TBackendRequestChecker) (socketserver *ht
A <a href="http://www.frankerfacez.com/">FrankerFaceZ</a> Service
&mdash; CatBag by <a href="http://www.twitch.tv/wolsk">Wolsk</a>
</div>
</div>`), 0600)
</div>`), 0644)
conf := &ConfigFile{
ServerID: 20,