2022-12-28 01:54:38 +02:00
|
|
|
package components
|
|
|
|
|
|
|
|
// for running common actions
|
|
|
|
type Actions struct {
|
|
|
|
t *TestDriver
|
|
|
|
}
|
|
|
|
|
|
|
|
func (self *Actions) ContinueMerge() {
|
|
|
|
self.t.Views().current().Press(self.t.keys.Universal.CreateRebaseOptionsMenu)
|
|
|
|
|
2022-12-28 02:00:22 +02:00
|
|
|
self.t.ExpectPopup().Menu().
|
2022-12-28 01:54:38 +02:00
|
|
|
Title(Equals("Rebase Options")).
|
|
|
|
Select(Contains("continue")).
|
|
|
|
Confirm()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (self *Actions) ContinueRebase() {
|
|
|
|
self.ContinueMerge()
|
|
|
|
}
|
2023-02-22 13:25:18 +02:00
|
|
|
|
|
|
|
func (self *Actions) AcknowledgeConflicts() {
|
|
|
|
self.t.ExpectPopup().Confirmation().
|
|
|
|
Title(Equals("Auto-merge failed")).
|
|
|
|
Content(Contains("Conflicts!")).
|
|
|
|
Confirm()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (self *Actions) ContinueOnConflictsResolved() {
|
|
|
|
self.t.ExpectPopup().Confirmation().
|
|
|
|
Title(Equals("continue")).
|
|
|
|
Content(Contains("all merge conflicts resolved. Continue?")).
|
|
|
|
Confirm()
|
|
|
|
}
|
2023-02-23 13:29:40 +02:00
|
|
|
|
|
|
|
func (self *Actions) ConfirmDiscardLines() {
|
|
|
|
self.t.ExpectPopup().Confirmation().
|
|
|
|
Title(Equals("Unstage lines")).
|
|
|
|
Content(Contains("Are you sure you want to delete the selected lines")).
|
|
|
|
Confirm()
|
|
|
|
}
|