1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2026-06-20 01:19:23 +02:00

move popup assertions into a struct

This commit is contained in:
Jesse Duffield
2022-12-28 11:00:22 +11:00
parent 7aa843c75a
commit 9fef4447b6
33 changed files with 130 additions and 120 deletions
+1 -1
View File
@@ -8,7 +8,7 @@ type Actions struct {
func (self *Actions) ContinueMerge() {
self.t.Views().current().Press(self.t.keys.Universal.CreateRebaseOptionsMenu)
self.t.ExpectMenu().
self.t.ExpectPopup().Menu().
Title(Equals("Rebase Options")).
Select(Contains("continue")).
Confirm()
+70
View File
@@ -0,0 +1,70 @@
package components
type Popup struct {
t *TestDriver
}
func (self *Popup) Confirmation() *ConfirmationAsserter {
self.inConfirm()
return &ConfirmationAsserter{t: self.t}
}
func (self *Popup) inConfirm() {
self.t.assertWithRetries(func() (bool, string) {
currentView := self.t.gui.CurrentContext().GetView()
return currentView.Name() == "confirmation" && !currentView.Editable, "Expected confirmation popup to be focused"
})
}
func (self *Popup) Prompt() *PromptAsserter {
self.inPrompt()
return &PromptAsserter{t: self.t}
}
func (self *Popup) inPrompt() {
self.t.assertWithRetries(func() (bool, string) {
currentView := self.t.gui.CurrentContext().GetView()
return currentView.Name() == "confirmation" && currentView.Editable, "Expected prompt popup to be focused"
})
}
func (self *Popup) Alert() *AlertAsserter {
self.inAlert()
return &AlertAsserter{t: self.t}
}
func (self *Popup) inAlert() {
// basically the same thing as a confirmation popup with the current implementation
self.t.assertWithRetries(func() (bool, string) {
currentView := self.t.gui.CurrentContext().GetView()
return currentView.Name() == "confirmation" && !currentView.Editable, "Expected alert popup to be focused"
})
}
func (self *Popup) Menu() *MenuAsserter {
self.inMenu()
return &MenuAsserter{t: self.t}
}
func (self *Popup) inMenu() {
self.t.assertWithRetries(func() (bool, string) {
return self.t.gui.CurrentContext().GetView().Name() == "menu", "Expected popup menu to be focused"
})
}
func (self *Popup) CommitMessagePanel() *CommitMessagePanelAsserter {
self.inCommitMessagePanel()
return &CommitMessagePanelAsserter{t: self.t}
}
func (self *Popup) inCommitMessagePanel() {
self.t.assertWithRetries(func() (bool, string) {
currentView := self.t.gui.CurrentContext().GetView()
return currentView.Name() == "commitMessage", "Expected commit message panel to be focused"
})
}
+5 -65
View File
@@ -133,76 +133,16 @@ func (self *TestDriver) inListContext() {
})
}
func (self *TestDriver) ExpectConfirmation() *ConfirmationAsserter {
self.inConfirm()
return &ConfirmationAsserter{t: self}
}
func (self *TestDriver) inConfirm() {
self.assertWithRetries(func() (bool, string) {
currentView := self.gui.CurrentContext().GetView()
return currentView.Name() == "confirmation" && !currentView.Editable, "Expected confirmation popup to be focused"
})
}
func (self *TestDriver) ExpectPrompt() *PromptAsserter {
self.inPrompt()
return &PromptAsserter{t: self}
}
func (self *TestDriver) inPrompt() {
self.assertWithRetries(func() (bool, string) {
currentView := self.gui.CurrentContext().GetView()
return currentView.Name() == "confirmation" && currentView.Editable, "Expected prompt popup to be focused"
})
}
func (self *TestDriver) ExpectAlert() *AlertAsserter {
self.inAlert()
return &AlertAsserter{t: self}
}
func (self *TestDriver) inAlert() {
// basically the same thing as a confirmation popup with the current implementation
self.assertWithRetries(func() (bool, string) {
currentView := self.gui.CurrentContext().GetView()
return currentView.Name() == "confirmation" && !currentView.Editable, "Expected alert popup to be focused"
})
}
func (self *TestDriver) ExpectMenu() *MenuAsserter {
self.inMenu()
return &MenuAsserter{t: self}
}
func (self *TestDriver) inMenu() {
self.assertWithRetries(func() (bool, string) {
return self.gui.CurrentContext().GetView().Name() == "menu", "Expected popup menu to be focused"
})
}
func (self *TestDriver) ExpectCommitMessagePanel() *CommitMessagePanelAsserter {
self.inCommitMessagePanel()
return &CommitMessagePanelAsserter{t: self}
}
func (self *TestDriver) inCommitMessagePanel() {
self.assertWithRetries(func() (bool, string) {
currentView := self.gui.CurrentContext().GetView()
return currentView.Name() == "commitMessage", "Expected commit message panel to be focused"
})
}
// for making assertions on lazygit views
func (self *TestDriver) Views() *Views {
return &Views{t: self}
}
// for interacting with popups
func (self *TestDriver) ExpectPopup() *Popup {
return &Popup{t: self}
}
// for making assertions through git itself
func (self *TestDriver) Git() *Git {
return &Git{assertionHelper: self.assertionHelper, shell: self.shell}
+3 -3
View File
@@ -19,14 +19,14 @@ var Basic = NewIntegrationTest(NewIntegrationTestArgs{
t.Views().Commits().
Press(keys.Commits.ViewBisectOptions)
t.ExpectMenu().Title(Equals("Bisect")).Select(MatchesRegexp(`mark .* as bad`)).Confirm()
t.ExpectPopup().Menu().Title(Equals("Bisect")).Select(MatchesRegexp(`mark .* as bad`)).Confirm()
}
markCommitAsGood := func() {
t.Views().Commits().
Press(keys.Commits.ViewBisectOptions)
t.ExpectMenu().Title(Equals("Bisect")).Select(MatchesRegexp(`mark .* as good`)).Confirm()
t.ExpectPopup().Menu().Title(Equals("Bisect")).Select(MatchesRegexp(`mark .* as good`)).Confirm()
}
t.Views().Commits().
@@ -49,7 +49,7 @@ var Basic = NewIntegrationTest(NewIntegrationTestArgs{
markCommitAsGood()
// commit 5 is the culprit because we marked 4 as good and 5 as bad.
t.ExpectAlert().Title(Equals("Bisect complete")).Content(MatchesRegexp("(?s)commit 05.*Do you want to reset")).Confirm()
t.ExpectPopup().Alert().Title(Equals("Bisect complete")).Content(MatchesRegexp("(?s)commit 05.*Do you want to reset")).Confirm()
}).
IsFocused().
Content(Contains("commit 04"))
@@ -32,9 +32,9 @@ var FromOtherBranch = NewIntegrationTest(NewIntegrationTestArgs{
SelectNextItem().
Press(keys.Commits.ViewBisectOptions).
Tap(func() {
t.ExpectMenu().Title(Equals("Bisect")).Select(MatchesRegexp(`mark .* as good`)).Confirm()
t.ExpectPopup().Menu().Title(Equals("Bisect")).Select(MatchesRegexp(`mark .* as good`)).Confirm()
t.ExpectAlert().Title(Equals("Bisect complete")).Content(MatchesRegexp("(?s)commit 08.*Do you want to reset")).Confirm()
t.ExpectPopup().Alert().Title(Equals("Bisect complete")).Content(MatchesRegexp("(?s)commit 08.*Do you want to reset")).Confirm()
t.Views().Information().Content(DoesNotContain("bisecting"))
}).
@@ -27,9 +27,9 @@ var CheckoutByName = NewIntegrationTest(NewIntegrationTestArgs{
SelectNextItem().
Press(keys.Branches.CheckoutBranchByName).
Tap(func() {
t.ExpectPrompt().Title(Equals("Branch name:")).Type("new-branch").Confirm()
t.ExpectPopup().Prompt().Title(Equals("Branch name:")).Type("new-branch").Confirm()
t.ExpectAlert().Title(Equals("Branch not found")).Content(Equals("Branch not found. Create a new branch named new-branch?")).Confirm()
t.ExpectPopup().Alert().Title(Equals("Branch not found")).Content(Equals("Branch not found. Create a new branch named new-branch?")).Confirm()
}).
Lines(
MatchesRegexp(`\*.*new-branch`).IsSelected(),
+2 -2
View File
@@ -26,12 +26,12 @@ var Delete = NewIntegrationTest(NewIntegrationTestArgs{
).
Press(keys.Universal.Remove).
Tap(func() {
t.ExpectAlert().Title(Equals("Error")).Content(Contains("You cannot delete the checked out branch!")).Confirm()
t.ExpectPopup().Alert().Title(Equals("Error")).Content(Contains("You cannot delete the checked out branch!")).Confirm()
}).
SelectNextItem().
Press(keys.Universal.Remove).
Tap(func() {
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("Delete Branch")).
Content(Contains("Are you sure you want to delete the branch 'branch-one'?")).
Confirm()
+3 -3
View File
@@ -30,12 +30,12 @@ var Rebase = NewIntegrationTest(NewIntegrationTestArgs{
SelectNextItem().
Press(keys.Branches.RebaseBranch)
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("Rebasing")).
Content(Contains("Are you sure you want to rebase 'first-change-branch' on top of 'second-change-branch'?")).
Confirm()
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("Auto-merge failed")).
Content(Contains("Conflicts!")).
Confirm()
@@ -51,7 +51,7 @@ var Rebase = NewIntegrationTest(NewIntegrationTestArgs{
t.Views().Information().Content(Contains("rebasing"))
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("continue")).
Content(Contains("all merge conflicts resolved. Continue?")).
Confirm()
@@ -36,14 +36,14 @@ var RebaseAndDrop = NewIntegrationTest(NewIntegrationTestArgs{
SelectNextItem().
Press(keys.Branches.RebaseBranch)
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("Rebasing")).
Content(Contains("Are you sure you want to rebase 'first-change-branch' on top of 'second-change-branch'?")).
Confirm()
t.Views().Information().Content(Contains("rebasing"))
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("Auto-merge failed")).
Content(Contains("Conflicts!")).
Confirm()
@@ -78,7 +78,7 @@ var RebaseAndDrop = NewIntegrationTest(NewIntegrationTestArgs{
IsFocused().
PressPrimaryAction()
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("continue")).
Content(Contains("all merge conflicts resolved. Continue?")).
Confirm()
+1 -1
View File
@@ -35,7 +35,7 @@ var Reset = NewIntegrationTest(NewIntegrationTestArgs{
SelectNextItem().
Press(keys.Commits.ViewResetOptions)
t.ExpectMenu().
t.ExpectPopup().Menu().
Title(Contains("reset to other-branch")).
Select(Contains("hard reset")).
Confirm()
+1 -1
View File
@@ -27,7 +27,7 @@ var Suggestions = NewIntegrationTest(NewIntegrationTestArgs{
// we expect the first suggestion to be the branch we want because it most
// closely matches what we typed in
t.ExpectPrompt().
t.ExpectPopup().Prompt().
Title(Equals("Branch name:")).
Type("branch-to").
SuggestionTopLines(Contains("branch-to-checkout")).
@@ -60,7 +60,7 @@ var CherryPick = NewIntegrationTest(NewIntegrationTestArgs{
).
Press(keys.Commits.PasteCommits).
Tap(func() {
t.ExpectAlert().
t.ExpectPopup().Alert().
Title(Equals("Cherry-Pick")).
Content(Contains("Are you sure you want to cherry-pick the copied commits onto this branch?")).
Confirm()
@@ -47,9 +47,9 @@ var CherryPickConflicts = NewIntegrationTest(NewIntegrationTestArgs{
).
Press(keys.Commits.PasteCommits)
t.ExpectAlert().Title(Equals("Cherry-Pick")).Content(Contains("Are you sure you want to cherry-pick the copied commits onto this branch?")).Confirm()
t.ExpectPopup().Alert().Title(Equals("Cherry-Pick")).Content(Contains("Are you sure you want to cherry-pick the copied commits onto this branch?")).Confirm()
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("Auto-merge failed")).
Content(Contains("Conflicts!")).
Confirm()
@@ -65,7 +65,7 @@ var CherryPickConflicts = NewIntegrationTest(NewIntegrationTestArgs{
SelectNextItem().
PressPrimaryAction()
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("continue")).
Content(Contains("all merge conflicts resolved. Continue?")).
Confirm()
+1 -1
View File
@@ -27,7 +27,7 @@ var Commit = NewIntegrationTest(NewIntegrationTestArgs{
commitMessage := "my commit message"
t.ExpectCommitMessagePanel().Type(commitMessage).Confirm()
t.ExpectPopup().CommitMessagePanel().Type(commitMessage).Confirm()
t.Views().Commits().
Lines(
@@ -22,7 +22,7 @@ var CommitMultiline = NewIntegrationTest(NewIntegrationTestArgs{
PressPrimaryAction().
Press(keys.Files.CommitChanges)
t.ExpectCommitMessagePanel().Type("first line").AddNewline().AddNewline().Type("third line").Confirm()
t.ExpectPopup().CommitMessagePanel().Type("first line").AddNewline().AddNewline().Type("third line").Confirm()
t.Views().Commits().
Lines(
+1 -1
View File
@@ -28,7 +28,7 @@ var NewBranch = NewIntegrationTest(NewIntegrationTestArgs{
Press(keys.Universal.New).
Tap(func() {
branchName := "my-branch-name"
t.ExpectPrompt().Title(Contains("New Branch Name")).Type(branchName).Confirm()
t.ExpectPopup().Prompt().Title(Contains("New Branch Name")).Type(branchName).Confirm()
t.Git().CurrentBranchName(branchName)
}).
+1 -1
View File
@@ -23,7 +23,7 @@ var Revert = NewIntegrationTest(NewIntegrationTestArgs{
).
Press(keys.Commits.RevertCommit).
Tap(func() {
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("Revert commit")).
Content(MatchesRegexp(`Are you sure you want to revert \w+?`)).
Confirm()
+1 -1
View File
@@ -46,7 +46,7 @@ var Staged = NewIntegrationTest(NewIntegrationTestArgs{
Press(keys.Files.CommitChanges)
commitMessage := "my commit message"
t.ExpectCommitMessagePanel().Type(commitMessage).Confirm()
t.ExpectPopup().CommitMessagePanel().Type(commitMessage).Confirm()
t.Views().Commits().
Lines(
@@ -46,7 +46,7 @@ var StagedWithoutHooks = NewIntegrationTest(NewIntegrationTestArgs{
Press(keys.Files.CommitChangesWithoutHook)
commitMessage := ": my commit message"
t.ExpectCommitMessagePanel().InitialText(Contains("WIP")).Type(commitMessage).Confirm()
t.ExpectPopup().CommitMessagePanel().InitialText(Contains("WIP")).Type(commitMessage).Confirm()
t.Views().Commits().
Lines(
+1 -1
View File
@@ -40,7 +40,7 @@ var Unstaged = NewIntegrationTest(NewIntegrationTestArgs{
Press(keys.Files.CommitChanges)
commitMessage := "my commit message"
t.ExpectCommitMessagePanel().Type(commitMessage).Confirm()
t.ExpectPopup().CommitMessagePanel().Type(commitMessage).Confirm()
t.Views().Commits().
Lines(
@@ -61,11 +61,11 @@ var FormPrompts = NewIntegrationTest(NewIntegrationTestArgs{
IsFocused().
Press("a")
t.ExpectPrompt().Title(Equals("Enter a file name")).Type("my file").Confirm()
t.ExpectPopup().Prompt().Title(Equals("Enter a file name")).Type("my file").Confirm()
t.ExpectMenu().Title(Equals("Choose file content")).Select(Contains("bar")).Confirm()
t.ExpectPopup().Menu().Title(Equals("Choose file content")).Select(Contains("bar")).Confirm()
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("Are you sure?")).
Content(Equals("Are you REALLY sure you want to make this file? Up to you buddy.")).
Confirm()
@@ -50,9 +50,9 @@ var MenuFromCommand = NewIntegrationTest(NewIntegrationTestArgs{
Focus().
Press("a")
t.ExpectMenu().Title(Equals("Choose commit message")).Select(Contains("bar")).Confirm()
t.ExpectPopup().Menu().Title(Equals("Choose commit message")).Select(Contains("bar")).Confirm()
t.ExpectPrompt().Title(Equals("Description")).Type(" my branch").Confirm()
t.ExpectPopup().Prompt().Title(Equals("Description")).Type(" my branch").Confirm()
t.Views().Files().
Focus().
@@ -48,12 +48,12 @@ var MenuFromCommandsOutput = NewIntegrationTest(NewIntegrationTestArgs{
Focus().
Press("a")
t.ExpectPrompt().
t.ExpectPopup().Prompt().
Title(Equals("Which git command do you want to run?")).
InitialText(Equals("branch")).
Confirm()
t.ExpectMenu().Title(Equals("Branch:")).Select(Equals("master")).Confirm()
t.ExpectPopup().Menu().Title(Equals("Branch:")).Select(Equals("master")).Confirm()
t.Git().CurrentBranchName("master")
},
@@ -59,11 +59,11 @@ var MultiplePrompts = NewIntegrationTest(NewIntegrationTestArgs{
IsFocused().
Press("a")
t.ExpectPrompt().Title(Equals("Enter a file name")).Type("myfile").Confirm()
t.ExpectPopup().Prompt().Title(Equals("Enter a file name")).Type("myfile").Confirm()
t.ExpectMenu().Title(Equals("Choose file content")).Select(Contains("bar")).Confirm()
t.ExpectPopup().Menu().Title(Equals("Choose file content")).Select(Contains("bar")).Confirm()
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("Are you sure?")).
Content(Equals("Are you REALLY sure you want to make this file? Up to you buddy.")).
Confirm()
+2 -2
View File
@@ -30,7 +30,7 @@ var Diff = NewIntegrationTest(NewIntegrationTestArgs{
).
Press(keys.Universal.DiffingMenu)
t.ExpectMenu().Title(Equals("Diffing")).Select(Contains(`diff branch-a`)).Confirm()
t.ExpectPopup().Menu().Title(Equals("Diffing")).Select(Contains(`diff branch-a`)).Confirm()
t.Views().Branches().
IsFocused().
@@ -66,7 +66,7 @@ var Diff = NewIntegrationTest(NewIntegrationTestArgs{
IsFocused().
Press(keys.Universal.DiffingMenu)
t.ExpectMenu().Title(Equals("Diffing")).Select(Contains("reverse diff direction")).Confirm()
t.ExpectPopup().Menu().Title(Equals("Diffing")).Select(Contains("reverse diff direction")).Confirm()
t.Views().Information().Content(Contains("showing output for: git diff branch-a branch-b -R"))
t.Views().Main().Content(Contains("-second line"))
},
@@ -30,7 +30,7 @@ var DiffAndApplyPatch = NewIntegrationTest(NewIntegrationTestArgs{
).
Press(keys.Universal.DiffingMenu)
t.ExpectMenu().Title(Equals("Diffing")).Select(Equals("diff branch-a")).Confirm()
t.ExpectPopup().Menu().Title(Equals("Diffing")).Select(Equals("diff branch-a")).Confirm()
t.Views().Information().Content(Contains("showing output for: git diff branch-a branch-a"))
@@ -60,14 +60,14 @@ var DiffAndApplyPatch = NewIntegrationTest(NewIntegrationTestArgs{
PressPrimaryAction(). // add the file to the patch
Press(keys.Universal.DiffingMenu).
Tap(func() {
t.ExpectMenu().Title(Equals("Diffing")).Select(Contains("exit diff mode")).Confirm()
t.ExpectPopup().Menu().Title(Equals("Diffing")).Select(Contains("exit diff mode")).Confirm()
t.Views().Information().Content(DoesNotContain("building patch"))
}).
Press(keys.Universal.CreatePatchOptionsMenu)
// adding the regex '$' here to distinguish the menu item from the 'apply patch in reverse' item
t.ExpectMenu().Title(Equals("Patch Options")).Select(MatchesRegexp("apply patch$")).Confirm()
t.ExpectPopup().Menu().Title(Equals("Patch Options")).Select(MatchesRegexp("apply patch$")).Confirm()
t.Views().Files().
Focus().
+2 -2
View File
@@ -28,7 +28,7 @@ var DiffCommits = NewIntegrationTest(NewIntegrationTestArgs{
).
Press(keys.Universal.DiffingMenu).
Tap(func() {
t.ExpectMenu().Title(Equals("Diffing")).Select(MatchesRegexp(`diff \w+`)).Confirm()
t.ExpectPopup().Menu().Title(Equals("Diffing")).Select(MatchesRegexp(`diff \w+`)).Confirm()
t.Views().Information().Content(Contains("showing output for: git diff"))
}).
@@ -40,7 +40,7 @@ var DiffCommits = NewIntegrationTest(NewIntegrationTestArgs{
}).
Press(keys.Universal.DiffingMenu).
Tap(func() {
t.ExpectMenu().Title(Equals("Diffing")).Select(Contains("reverse diff direction")).Confirm()
t.ExpectPopup().Menu().Title(Equals("Diffing")).Select(Contains("reverse diff direction")).Confirm()
t.Views().Main().Content(Contains("+second line\n+third line"))
}).
@@ -85,7 +85,7 @@ var DiscardChanges = NewIntegrationTest(NewIntegrationTestArgs{
SelectedLine(Contains(file.status + " " + file.label)).
Press(keys.Universal.Remove)
t.ExpectMenu().Title(Equals(file.menuTitle)).Select(Contains("discard all changes")).Confirm()
t.ExpectPopup().Menu().Title(Equals(file.menuTitle)).Select(Contains("discard all changes")).Confirm()
}
}
@@ -99,7 +99,7 @@ var DiscardChanges = NewIntegrationTest(NewIntegrationTestArgs{
{status: "DU", label: "deleted-us.txt", menuTitle: "deleted-us.txt"},
})
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("continue")).
Content(Contains("all merge conflicts resolved. Continue?")).
Cancel()
@@ -41,7 +41,7 @@ var AmendMerge = NewIntegrationTest(NewIntegrationTestArgs{
Focus().
Press(keys.Commits.AmendToCommit)
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("Amend Commit")).
Content(Contains("Are you sure you want to amend this commit with your staged files?")).
Confirm()
@@ -18,7 +18,7 @@ var ConfirmOnQuit = NewIntegrationTest(NewIntegrationTestArgs{
IsFocused().
Press(keys.Universal.Quit)
t.ExpectConfirmation().
t.ExpectPopup().Confirmation().
Title(Equals("")).
Content(Contains("Are you sure you want to quit?")).
Confirm()
+1 -1
View File
@@ -28,7 +28,7 @@ var Rename = NewIntegrationTest(NewIntegrationTestArgs{
SelectNextItem().
Press(keys.Stash.RenameStash).
Tap(func() {
t.ExpectPrompt().Title(Equals("Rename stash: stash@{1}")).Type(" baz").Confirm()
t.ExpectPopup().Prompt().Title(Equals("Rename stash: stash@{1}")).Type(" baz").Confirm()
}).
SelectedLine(Equals("On master: foo baz"))
},
+2 -2
View File
@@ -25,9 +25,9 @@ var Stash = NewIntegrationTest(NewIntegrationTestArgs{
).
Press(keys.Files.ViewStashOptions)
t.ExpectMenu().Title(Equals("Stash options")).Select(MatchesRegexp("stash all changes$")).Confirm()
t.ExpectPopup().Menu().Title(Equals("Stash options")).Select(MatchesRegexp("stash all changes$")).Confirm()
t.ExpectPrompt().Title(Equals("Stash changes")).Type("my stashed file").Confirm()
t.ExpectPopup().Prompt().Title(Equals("Stash changes")).Type("my stashed file").Confirm()
t.Views().Stash().
Lines(
@@ -27,9 +27,9 @@ var StashIncludingUntrackedFiles = NewIntegrationTest(NewIntegrationTestArgs{
).
Press(keys.Files.ViewStashOptions)
t.ExpectMenu().Title(Equals("Stash options")).Select(Contains("stash all changes including untracked files")).Confirm()
t.ExpectPopup().Menu().Title(Equals("Stash options")).Select(Contains("stash all changes including untracked files")).Confirm()
t.ExpectPrompt().Title(Equals("Stash changes")).Type("my stashed file").Confirm()
t.ExpectPopup().Prompt().Title(Equals("Stash changes")).Type("my stashed file").Confirm()
t.Views().Stash().
Lines(