0
0
Fork 0
mirror of https://github.com/matrix-org/dendrite synced 2024-11-16 14:50:52 +01:00

Stub APIs for sytest (#261)

This commit is contained in:
Mark Haines 2017-09-22 17:28:29 +01:00 committed by GitHub
parent 8a395b0262
commit 42f264119f

View file

@ -345,4 +345,23 @@ func Setup(
return util.JSONResponse{Code: 200, JSON: struct{}{}}
}),
).Methods("PUT", "OPTIONS")
// Stub implementations for sytest
r0mux.Handle("/events",
common.MakeAPI("events", func(req *http.Request) util.JSONResponse {
return util.JSONResponse{Code: 200, JSON: map[string]interface{}{
"chunk": []interface{}{},
"start": "",
"end": "",
}}
}),
).Methods("GET")
r0mux.Handle("/initialSync",
common.MakeAPI("initial_sync", func(req *http.Request) util.JSONResponse {
return util.JSONResponse{Code: 200, JSON: map[string]interface{}{
"end": "",
}}
}),
).Methods("GET")
}