diff options
author | Ethan Koenig <etk39@cornell.edu> | 2017-04-30 02:30:12 -0400 |
---|---|---|
committer | Bo-Yi Wu <appleboy.tw@gmail.com> | 2017-04-30 14:30:12 +0800 |
commit | 66c803fae25f966a23d012de91e281e229b62cd4 (patch) | |
tree | c021213252648b23eca65b259b666488b7759875 /models | |
parent | 0308d44a16d7bdcda75c1e946dc06efca48ed624 (diff) | |
download | gitea-66c803fae25f966a23d012de91e281e229b62cd4.tar.gz gitea-66c803fae25f966a23d012de91e281e229b62cd4.zip |
MySQL, Postgres integration tests in drone (#1638)
* MySQL, Postgres integration tests in drone
* Fix .drone.yml
* sign drone
* resign drone
Diffstat (limited to 'models')
-rw-r--r-- | models/attachment_test.go | 6 | ||||
-rw-r--r-- | models/fixtures/attachment.yml | 16 | ||||
-rw-r--r-- | models/fixtures/pull_request.yml | 2 |
3 files changed, 12 insertions, 12 deletions
diff --git a/models/attachment_test.go b/models/attachment_test.go index 5fdac31b41..d568e39431 100644 --- a/models/attachment_test.go +++ b/models/attachment_test.go @@ -13,7 +13,7 @@ import ( func TestIncreaseDownloadCount(t *testing.T) { assert.NoError(t, PrepareTestDatabase()) - attachment, err := GetAttachmentByUUID("1234567890") + attachment, err := GetAttachmentByUUID("a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a11") assert.NoError(t, err) assert.Equal(t, int64(0), attachment.DownloadCount) @@ -21,7 +21,7 @@ func TestIncreaseDownloadCount(t *testing.T) { err = attachment.IncreaseDownloadCount() assert.NoError(t, err) - attachment, err = GetAttachmentByUUID("1234567890") + attachment, err = GetAttachmentByUUID("a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a11") assert.NoError(t, err) assert.Equal(t, int64(1), attachment.DownloadCount) } @@ -53,7 +53,7 @@ func TestDeleteAttachments(t *testing.T) { err = DeleteAttachment(&Attachment{ID: 8}, false) assert.NoError(t, err) - attachment, err := GetAttachmentByUUID("test-12345") + attachment, err := GetAttachmentByUUID("a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a18") assert.Error(t, err) assert.True(t, IsErrAttachmentNotExist(err)) assert.Nil(t, attachment) diff --git a/models/fixtures/attachment.yml b/models/fixtures/attachment.yml index 99bd5453ee..f196aa4ea6 100644 --- a/models/fixtures/attachment.yml +++ b/models/fixtures/attachment.yml @@ -1,6 +1,6 @@ - id: 1 - uuid: 1234567890 + uuid: a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a11 issue_id: 1 comment_id: 0 name: attach1 @@ -9,7 +9,7 @@ - id: 2 - uuid: 1122334455 + uuid: a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a12 issue_id: 1 comment_id: 0 name: attach2 @@ -18,7 +18,7 @@ - id: 3 - uuid: comment-id-1 + uuid: a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a13 issue_id: 2 comment_id: 1 name: attach1 @@ -27,7 +27,7 @@ - id: 4 - uuid: comment-id-2 + uuid: a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a14 issue_id: 3 comment_id: 1 name: attach2 @@ -36,7 +36,7 @@ - id: 5 - uuid: comment-id-3 + uuid: a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a15 issue_id: 4 comment_id: 0 name: attach1 @@ -45,7 +45,7 @@ - id: 6 - uuid: comment-id-4 + uuid: a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a16 issue_id: 5 comment_id: 2 name: attach1 @@ -54,7 +54,7 @@ - id: 7 - uuid: comment-id-5 + uuid: a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a17 issue_id: 5 comment_id: 2 name: attach1 @@ -63,7 +63,7 @@ - id: 8 - uuid: test-12345 + uuid: a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a18 issue_id: 6 comment_id: 0 name: attach1 diff --git a/models/fixtures/pull_request.yml b/models/fixtures/pull_request.yml index 7946a0f8f7..d8313f9f90 100644 --- a/models/fixtures/pull_request.yml +++ b/models/fixtures/pull_request.yml @@ -16,7 +16,7 @@ - id: 2 type: 0 # gitea pull request - status: 1 # checking + status: 2 # mergable issue_id: 3 index: 3 head_repo_id: 1 |