diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2021-11-19 21:39:57 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-11-19 21:39:57 +0800 |
commit | fc3d0826096943b979717ed46c9a4cfd86e06106 (patch) | |
tree | 3143882ccf4dea3a8bf2a0de9c8da9a4efec26ce /integrations | |
parent | 7a0347315995b25bcb2dca4786504fb699b5f004 (diff) | |
download | gitea-fc3d0826096943b979717ed46c9a4cfd86e06106.tar.gz gitea-fc3d0826096943b979717ed46c9a4cfd86e06106.zip |
Move attachment into models/repo/ (#17650)
* Move attachment into models/repo/
* Fix test
* Fix bug
Diffstat (limited to 'integrations')
-rw-r--r-- | integrations/attachment_test.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/integrations/attachment_test.go b/integrations/attachment_test.go index 052f27605a..481104d73f 100644 --- a/integrations/attachment_test.go +++ b/integrations/attachment_test.go @@ -14,7 +14,7 @@ import ( "strings" "testing" - "code.gitea.io/gitea/models" + repo_model "code.gitea.io/gitea/models/repo" "code.gitea.io/gitea/modules/storage" "code.gitea.io/gitea/modules/test" @@ -122,7 +122,7 @@ func TestGetAttachment(t *testing.T) { t.Run(tc.name, func(t *testing.T) { //Write empty file to be available for response if tc.createFile { - _, err := storage.Attachments.Save(models.AttachmentRelativePath(tc.uuid), strings.NewReader("hello world"), -1) + _, err := storage.Attachments.Save(repo_model.AttachmentRelativePath(tc.uuid), strings.NewReader("hello world"), -1) assert.NoError(t, err) } //Actual test |