summaryrefslogtreecommitdiff
path: root/spec/finders/tags_finder_spec.rb
diff options
context:
space:
mode:
authorAlejandro Rodríguez <alejorro70@gmail.com>2016-09-27 00:07:31 -0300
committerAlejandro Rodríguez <alejorro70@gmail.com>2016-10-28 13:53:18 -0300
commitfa3bbd449efb69a42a2347c3c3fa08cd822c2471 (patch)
treecee7557e3a83dd18fb8f6162b9e7333f391e0ce4 /spec/finders/tags_finder_spec.rb
parent5742f4a6287927972790d9f20d671c505f149856 (diff)
downloadgitlab-ce-fa3bbd449efb69a42a2347c3c3fa08cd822c2471.tar.gz
Fix lightweight tags not processed correctly by GitTagPushService22271-drone-tag-pipeline-build
When we updated gitlab_git to 10.4.1, `tag.target` changed from pointing to the sha of the tag to the sha of the commit the tag points to. The problem is that only annotated tags have `object_sha`s, lightweight tags don't (it's nil), so (only) in their case we still need to use `tag.target`.
Diffstat (limited to 'spec/finders/tags_finder_spec.rb')
-rw-r--r--spec/finders/tags_finder_spec.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/spec/finders/tags_finder_spec.rb b/spec/finders/tags_finder_spec.rb
index 2ac810e478a..98b42e264dc 100644
--- a/spec/finders/tags_finder_spec.rb
+++ b/spec/finders/tags_finder_spec.rb
@@ -20,7 +20,7 @@ describe TagsFinder do
result = tags_finder.execute
recently_updated_tag = repository.tags.max do |a, b|
- repository.commit(a.target).committed_date <=> repository.commit(b.target).committed_date
+ repository.commit(a.dereferenced_target).committed_date <=> repository.commit(b.dereferenced_target).committed_date
end
expect(result.first.name).to eq(recently_updated_tag.name)