summaryrefslogtreecommitdiff
path: root/handlers_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'handlers_test.go')
-rw-r--r--handlers_test.go21
1 files changed, 0 insertions, 21 deletions
diff --git a/handlers_test.go b/handlers_test.go
index f24bde4..c3bdabf 100644
--- a/handlers_test.go
+++ b/handlers_test.go
@@ -64,27 +64,6 @@ func TestHTTPVersion(t *testing.T) {
testHandler(t, version, cases, setup)
}
-func TestHTTPRegister(t *testing.T) {
- cases := []httpCase{
- {"basic", "POST", `{"username":"testuser","password":"mypass"}`, "", http.StatusOK},
- {"missing-password", "POST", `{"username":"testuser"}`, "", http.StatusBadRequest},
- {"missing-username", "POST", `{"password":"mypass"}`, "", http.StatusBadRequest},
- {"unknown-field", "POST", `{"username":"testuser","password":"mypass","foo":"bar"}`, "", http.StatusBadRequest},
- {"invalid-json", "POST", `{username":"testuser","password":"mypass"}`, "", http.StatusBadRequest},
- }
-
- setup := func(t *testing.T) *sql.DB {
- db, _ := emptyDB(t)
- err := MigrateToLatest(db)
- if err != nil {
- t.Fatalf("Could not migrate test database: %v", err)
- }
- return db
- }
-
- testHandler(t, ApiRegistration, cases, setup)
-}
-
func TestHTTPAuthenticate(t *testing.T) {
cases := []httpCase{
{"basic", "POST", `{"username":"testuser","password":"mypass"}`, "", http.StatusOK},