diff options
author | KN4CK3R <admin@oldschoolhack.me> | 2022-09-29 05:27:33 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-09-29 05:27:33 +0200 |
commit | b7309b8ccb16f6303ae300b755baef9f9713d457 (patch) | |
tree | cab46a2eafee748123b76f1d52d00037d44a4bd9 /tests/integration/api_user_orgs_test.go | |
parent | 1dfa28ffa557720d164a351783be64c9a47a0adb (diff) | |
download | gitea-b7309b8ccb16f6303ae300b755baef9f9713d457.tar.gz gitea-b7309b8ccb16f6303ae300b755baef9f9713d457.zip |
Add name field for org api (#21270)
related #21205
The field `UserName` is not really usefull for an organization.
This adds a second `Name` field.
The [GitHub API](https://docs.github.com/en/rest/orgs/orgs#get-an-organization) uses `name` too. `UserName` should be deprecated then.
Diffstat (limited to 'tests/integration/api_user_orgs_test.go')
-rw-r--r-- | tests/integration/api_user_orgs_test.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/integration/api_user_orgs_test.go b/tests/integration/api_user_orgs_test.go index 622dfdcf21..c28bf391eb 100644 --- a/tests/integration/api_user_orgs_test.go +++ b/tests/integration/api_user_orgs_test.go @@ -32,6 +32,7 @@ func TestUserOrgs(t *testing.T) { assert.Equal(t, []*api.Organization{ { ID: 17, + Name: user17.Name, UserName: user17.Name, FullName: user17.FullName, AvatarURL: user17.AvatarLink(), @@ -42,6 +43,7 @@ func TestUserOrgs(t *testing.T) { }, { ID: 3, + Name: user3.Name, UserName: user3.Name, FullName: user3.FullName, AvatarURL: user3.AvatarLink(), @@ -99,6 +101,7 @@ func TestMyOrgs(t *testing.T) { assert.Equal(t, []*api.Organization{ { ID: 17, + Name: user17.Name, UserName: user17.Name, FullName: user17.FullName, AvatarURL: user17.AvatarLink(), @@ -109,6 +112,7 @@ func TestMyOrgs(t *testing.T) { }, { ID: 3, + Name: user3.Name, UserName: user3.Name, FullName: user3.FullName, AvatarURL: user3.AvatarLink(), |