aboutsummaryrefslogtreecommitdiffstats
path: root/bridge/github/export_test.go
diff options
context:
space:
mode:
authorMichael Muré <batolettre@gmail.com>2019-11-19 19:25:43 +0100
committerGitHub <noreply@github.com>2019-11-19 19:25:43 +0100
commite01cefff9826589b77bd34464301f196112d68f7 (patch)
tree44b32dfc7727c957ce7e364c6dc631ba8d76a4a5 /bridge/github/export_test.go
parent67c82f4a2d683e746df5f8af9e0725acd252d29d (diff)
parent8ffe2a9b03f5d489e12d2d4d2677bbe67a1b53d7 (diff)
downloadgit-bug-e01cefff9826589b77bd34464301f196112d68f7.tar.gz
Merge pull request #247 from MichaelMure/bridge-origin
bridge: move keyOrigin to core package
Diffstat (limited to 'bridge/github/export_test.go')
-rw-r--r--bridge/github/export_test.go10
1 files changed, 5 insertions, 5 deletions
diff --git a/bridge/github/export_test.go b/bridge/github/export_test.go
index e39ace01..dba72f3f 100644
--- a/bridge/github/export_test.go
+++ b/bridge/github/export_test.go
@@ -233,27 +233,27 @@ func TestPushPull(t *testing.T) {
for _, op := range tt.bug.Snapshot().Operations {
// Check if the originals operations (*not* SetMetadata) are tagged properly
if _, ok := op.(*bug.SetMetadataOperation); !ok {
- _, haveIDMetadata := op.GetMetadata(keyGithubId)
+ _, haveIDMetadata := op.GetMetadata(metaKeyGithubId)
require.True(t, haveIDMetadata)
- _, haveURLMetada := op.GetMetadata(keyGithubUrl)
+ _, haveURLMetada := op.GetMetadata(metaKeyGithubUrl)
require.True(t, haveURLMetada)
}
}
// get bug github ID
- bugGithubID, ok := tt.bug.Snapshot().GetCreateMetadata(keyGithubId)
+ bugGithubID, ok := tt.bug.Snapshot().GetCreateMetadata(metaKeyGithubId)
require.True(t, ok)
// retrieve bug from backendTwo
- importedBug, err := backendTwo.ResolveBugCreateMetadata(keyGithubId, bugGithubID)
+ importedBug, err := backendTwo.ResolveBugCreateMetadata(metaKeyGithubId, bugGithubID)
require.NoError(t, err)
// verify bug have same number of original operations
require.Len(t, importedBug.Snapshot().Operations, tt.numOrOp)
// verify bugs are taged with origin=github
- issueOrigin, ok := importedBug.Snapshot().GetCreateMetadata(keyOrigin)
+ issueOrigin, ok := importedBug.Snapshot().GetCreateMetadata(core.MetaKeyOrigin)
require.True(t, ok)
require.Equal(t, issueOrigin, target)