diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2022-06-05 03:18:50 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-04 20:18:50 +0100 |
commit | 12c742f8dc25e4148c44d1265d119c35f161bf74 (patch) | |
tree | 0c35f1de4cf7bdea1dfc8b03468f3616d0c82796 /integrations/api_releases_test.go | |
parent | 449ea6005fb613212102126ff267f5c16f7c40b8 (diff) | |
download | gitea-12c742f8dc25e4148c44d1265d119c35f161bf74.tar.gz gitea-12c742f8dc25e4148c44d1265d119c35f161bf74.zip |
Fix order by parameter (#19849)
Upgrade builder to v0.3.11
Upgrade xorm to v1.3.1 and fixed some hidden bugs.
Replace #19821
Replace #19834
Included #19850
Co-authored-by: zeripath <art27@cantab.net>
Diffstat (limited to 'integrations/api_releases_test.go')
-rw-r--r-- | integrations/api_releases_test.go | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/integrations/api_releases_test.go b/integrations/api_releases_test.go index ebb76cc163..74639e9007 100644 --- a/integrations/api_releases_test.go +++ b/integrations/api_releases_test.go @@ -84,12 +84,13 @@ func createNewReleaseUsingAPI(t *testing.T, session *TestSession, token string, var newRelease api.Release DecodeJSON(t, resp, &newRelease) - unittest.AssertExistsAndLoadBean(t, &models.Release{ + rel := &models.Release{ ID: newRelease.ID, TagName: newRelease.TagName, Title: newRelease.Title, - Note: newRelease.Note, - }) + } + unittest.AssertExistsAndLoadBean(t, rel) + assert.EqualValues(t, newRelease.Note, rel.Note) return &newRelease } @@ -137,12 +138,13 @@ func TestAPICreateAndUpdateRelease(t *testing.T) { resp = session.MakeRequest(t, req, http.StatusOK) DecodeJSON(t, resp, &newRelease) - unittest.AssertExistsAndLoadBean(t, &models.Release{ + rel := &models.Release{ ID: newRelease.ID, TagName: newRelease.TagName, Title: newRelease.Title, - Note: newRelease.Note, - }) + } + unittest.AssertExistsAndLoadBean(t, rel) + assert.EqualValues(t, rel.Note, newRelease.Note) } func TestAPICreateReleaseToDefaultBranch(t *testing.T) { |