mirror of
https://github.com/rpm-software-management/tito.git
synced 2025-02-23 20:22:46 +00:00
tests: adapt test_undo_tag() to the master → main change
This commit is contained in:
parent
6e0f1f12ef
commit
10b315b1a5
1 changed files with 3 additions and 3 deletions
|
@ -94,19 +94,19 @@ class SingleProjectTests(TitoGitTestFixture):
|
|||
|
||||
def test_undo_tag(self):
|
||||
os.chdir(self.repo_dir)
|
||||
original_head = getoutput('git show-ref -s refs/heads/master')
|
||||
original_head = getoutput('git show-ref -s refs/heads/main')
|
||||
|
||||
# Create tito tag, which adds a new commit and moves head.
|
||||
tito("tag --accept-auto-changelog --debug")
|
||||
tag = "%s-0.0.2-1" % PKG_NAME
|
||||
check_tag_exists(tag, offline=True)
|
||||
new_head = getoutput('git show-ref -s refs/heads/master')
|
||||
new_head = getoutput('git show-ref -s refs/heads/main')
|
||||
self.assertNotEqual(original_head, new_head)
|
||||
|
||||
# Undo tito tag, which rewinds one commit to original head.
|
||||
tito("tag -u")
|
||||
self.assertFalse(tag_exists_locally(tag))
|
||||
new_head = getoutput('git show-ref -s refs/heads/master')
|
||||
new_head = getoutput('git show-ref -s refs/heads/main')
|
||||
self.assertEqual(original_head, new_head)
|
||||
|
||||
def test_tag_with_custom_message(self):
|
||||
|
|
Loading…
Add table
Reference in a new issue