mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2025-09-20 14:13:28 +00:00
Update mock Gitea server
This commit is contained in:
@@ -33,6 +33,7 @@ func Handler() http.Handler {
|
||||
e.DELETE("/api/v1/repos/:owner/:name/hooks/:id", deleteRepoHook)
|
||||
e.POST("/api/v1/repos/:owner/:name/statuses/:commit", createRepoCommitStatus)
|
||||
e.GET("/api/v1/user/repos", getUserRepos)
|
||||
e.GET("/api/v1/version", getVersion)
|
||||
|
||||
return e
|
||||
}
|
||||
@@ -99,6 +100,10 @@ func getUserRepos(c *gin.Context) {
|
||||
}
|
||||
}
|
||||
|
||||
func getVersion(c *gin.Context) {
|
||||
c.JSON(200, map[string]interface{}{"version": "1.10"})
|
||||
}
|
||||
|
||||
const listRepoHookPayloads = `
|
||||
[
|
||||
{
|
||||
|
Reference in New Issue
Block a user