mirror of
https://gitea.com/gitea/tea.git
synced 2026-10-26 11:01:25 +01:00
fix(team,repo,org,wiki,auth): detect a kept admin permission, validate topics up front, page public members, name disabled wikis, treat auth switch's account as --user
Signed-off-by: bircni <bircni@icloud.com>
This commit is contained in:
12 files changed
+289
-64
No files matched your search
@@ -199,7 +199,11 @@ func TestTeamPermissionSetsEveryUnit(t *testing.T) {
|
||||
require.NoError(t, json.NewDecoder(r.Body).Decode(&body))
|
||||
sent = append(sent, body)
|
||||
}
|
||||
_, _ = w.Write([]byte(`{"id":5,"name":"devs","permission":"none","organization":{"username":"acme"}}`))
|
||||
permission := "none"
|
||||
if len(sent) > 0 {
|
||||
permission, _ = sent[len(sent)-1]["permission"].(string)
|
||||
}
|
||||
_, _ = w.Write([]byte(`{"id":5,"name":"devs","permission":"` + permission + `","organization":{"username":"acme"}}`))
|
||||
}))
|
||||
defer server.Close()
|
||||
deps, _, _ := serverDeps(t, server.URL)
|
||||
|
||||
Reference in new issue
Block a user