You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
41 lines
809 B
Go
41 lines
809 B
Go
package server
|
|
|
|
import (
|
|
"testing"
|
|
// "fmt"
|
|
// "net/http/httptest"
|
|
// "net/http"
|
|
|
|
// "strings"
|
|
// "time"
|
|
// "caj-larsson/bog/domain_dataswamp"
|
|
|
|
)
|
|
|
|
func TestApplication(t *testing.T) {
|
|
|
|
// file_service := domain_dataswamp.NewBogFileService(
|
|
// mock.NewMockUserAgentRepository(),
|
|
// mock.NewMockFileRepository(),
|
|
// 1000,
|
|
// time.Hour,
|
|
// )
|
|
|
|
// bog := Bog {
|
|
// router: new(http.ServeMux),
|
|
// file_service: file_service,
|
|
// address: "fake",
|
|
// }
|
|
// bog.routes()
|
|
// req := httptest.NewRequest("POST", "/apath", strings.NewReader("testdata"))
|
|
// req.Header.Add("User-Agent", "testingclient")
|
|
// req.Header.Add("Content-Length", "8")
|
|
// w := httptest.NewRecorder()
|
|
// bog.router.ServeHTTP(w, req)
|
|
|
|
// if (w.Code != 200){
|
|
// fmt.Printf("%v", w)
|
|
// t.Error("not ok")
|
|
// }
|
|
}
|