diff --git a/pkg/commands/git_commands/remote.go b/pkg/commands/git_commands/remote.go index 650a91c81..82a9d6a46 100644 --- a/pkg/commands/git_commands/remote.go +++ b/pkg/commands/git_commands/remote.go @@ -61,7 +61,7 @@ func (self *RemoteCommands) DeleteRemoteBranch(task gocui.Task, remoteName strin func (self *RemoteCommands) DeleteRemoteTag(task gocui.Task, remoteName string, tagName string) error { cmdArgs := NewGitCmd("push"). - Arg(remoteName, "--delete", tagName). + Arg(remoteName, "--delete", "refs/tags/"+tagName). ToArgv() return self.cmd.New(cmdArgs).PromptOnCredentialRequest(task).Run() diff --git a/pkg/integration/tests/tag/delete_remote_tag_when_branch_with_same_name_exists.go b/pkg/integration/tests/tag/delete_remote_tag_when_branch_with_same_name_exists.go index 2c3ff828e..6f2a03400 100644 --- a/pkg/integration/tests/tag/delete_remote_tag_when_branch_with_same_name_exists.go +++ b/pkg/integration/tests/tag/delete_remote_tag_when_branch_with_same_name_exists.go @@ -45,14 +45,8 @@ var DeleteRemoteTagWhenBranchWithSameNameExists = NewIntegrationTest(NewIntegrat Content(Equals("Are you sure you want to delete the remote tag 'xyz' from 'origin'?")). Confirm() - /* EXPECTED: t.ExpectToast(Equals("Remote tag deleted")) t.Shell().AssertRemoteTagNotFound("origin", "xyz") - ACTUAL: */ - t.ExpectPopup().Alert(). - Title(Equals("Error")). - Content(Contains("error: dst refspec xyz matches more than one")). - Confirm() }, })