Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'internal/service/commit/find_commits_test.go')
-rw-r--r--internal/service/commit/find_commits_test.go56
1 files changed, 32 insertions, 24 deletions
diff --git a/internal/service/commit/find_commits_test.go b/internal/service/commit/find_commits_test.go
index dd4c4d58f..3dff50d09 100644
--- a/internal/service/commit/find_commits_test.go
+++ b/internal/service/commit/find_commits_test.go
@@ -40,14 +40,16 @@ func TestFindCommitsFields(t *testing.T) {
Subject: []byte("Merge branch 'branch-merged' into 'master'"),
Body: []byte("Merge branch 'branch-merged' into 'master'\r\n\r\nadds bar folder and branch-test text file to check Repository merged_to_root_ref method\r\n\r\n\r\n\r\nSee merge request !12"),
Author: &gitalypb.CommitAuthor{
- Name: []byte("Job van der Voort"),
- Email: []byte("job@gitlab.com"),
- Date: &timestamp.Timestamp{Seconds: 1474987066},
+ Name: []byte("Job van der Voort"),
+ Email: []byte("job@gitlab.com"),
+ Date: &timestamp.Timestamp{Seconds: 1474987066},
+ Timezone: []byte("+0000"),
},
Committer: &gitalypb.CommitAuthor{
- Name: []byte("Job van der Voort"),
- Email: []byte("job@gitlab.com"),
- Date: &timestamp.Timestamp{Seconds: 1474987066},
+ Name: []byte("Job van der Voort"),
+ Email: []byte("job@gitlab.com"),
+ Date: &timestamp.Timestamp{Seconds: 1474987066},
+ Timezone: []byte("+0000"),
},
ParentIds: []string{
"1b12f15a11fc6e62177bef08f47bc7b5ce50b141",
@@ -63,14 +65,16 @@ func TestFindCommitsFields(t *testing.T) {
Subject: windows1251Message[:len(windows1251Message)-1],
Body: windows1251Message,
Author: &gitalypb.CommitAuthor{
- Name: []byte("Jacob Vosmaer"),
- Email: []byte("jacob@gitlab.com"),
- Date: &timestamp.Timestamp{Seconds: 1512132977},
+ Name: []byte("Jacob Vosmaer"),
+ Email: []byte("jacob@gitlab.com"),
+ Date: &timestamp.Timestamp{Seconds: 1512132977},
+ Timezone: []byte("+0100"),
},
Committer: &gitalypb.CommitAuthor{
- Name: []byte("Jacob Vosmaer"),
- Email: []byte("jacob@gitlab.com"),
- Date: &timestamp.Timestamp{Seconds: 1512132977},
+ Name: []byte("Jacob Vosmaer"),
+ Email: []byte("jacob@gitlab.com"),
+ Date: &timestamp.Timestamp{Seconds: 1512132977},
+ Timezone: []byte("+0100"),
},
ParentIds: []string{"e63f41fe459e62e1228fcef60d7189127aeba95a"},
BodySize: 49,
@@ -83,14 +87,16 @@ func TestFindCommitsFields(t *testing.T) {
Subject: []byte("Hello\xf0world"),
Body: []byte("Hello\xf0world\n"),
Author: &gitalypb.CommitAuthor{
- Name: []byte("Jacob Vosmaer"),
- Email: []byte("jacob@gitlab.com"),
- Date: &timestamp.Timestamp{Seconds: 1517328273},
+ Name: []byte("Jacob Vosmaer"),
+ Email: []byte("jacob@gitlab.com"),
+ Date: &timestamp.Timestamp{Seconds: 1517328273},
+ Timezone: []byte("+0100"),
},
Committer: &gitalypb.CommitAuthor{
- Name: []byte("Jacob Vosmaer"),
- Email: []byte("jacob@gitlab.com"),
- Date: &timestamp.Timestamp{Seconds: 1517328273},
+ Name: []byte("Jacob Vosmaer"),
+ Email: []byte("jacob@gitlab.com"),
+ Date: &timestamp.Timestamp{Seconds: 1517328273},
+ Timezone: []byte("+0100"),
},
ParentIds: []string{"60ecb67744cb56576c30214ff52294f8ce2def98"},
BodySize: 12,
@@ -103,14 +109,16 @@ func TestFindCommitsFields(t *testing.T) {
Subject: []byte("Add file larger than 1 mb"),
Body: []byte("Add file larger than 1 mb\n\nIn order to test Max File Size push rule we need a file larger than 1 MB\n"),
Author: &gitalypb.CommitAuthor{
- Name: []byte("Ruben Davila"),
- Email: []byte("rdavila84@gmail.com"),
- Date: &timestamp.Timestamp{Seconds: 1523247267},
+ Name: []byte("Ruben Davila"),
+ Email: []byte("rdavila84@gmail.com"),
+ Date: &timestamp.Timestamp{Seconds: 1523247267},
+ Timezone: []byte("-0500"),
},
Committer: &gitalypb.CommitAuthor{
- Name: []byte("Jacob Vosmaer"),
- Email: []byte("jacob@gitlab.com"),
- Date: &timestamp.Timestamp{Seconds: 1527855450},
+ Name: []byte("Jacob Vosmaer"),
+ Email: []byte("jacob@gitlab.com"),
+ Date: &timestamp.Timestamp{Seconds: 1527855450},
+ Timezone: []byte("+0200"),
},
ParentIds: []string{"60ecb67744cb56576c30214ff52294f8ce2def98"},
BodySize: 100,