summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJesse Duffield <jessedduffield@gmail.com>2023-08-01 22:19:04 +1000
committerJesse Duffield <jessedduffield@gmail.com>2023-08-01 22:19:04 +1000
commitf43fd7af79c712126c8d9f6e1933d26de9034c56 (patch)
tree96ff0a75b7b8d5575d1e9c681a87c32a6a81a75e
parenta200fccba95a0a85a028bb106836f8537526c71a (diff)
Wait in demo after setting caption
This looks nicer than waiting a second and then showing the caption as the action begins
-rw-r--r--pkg/integration/components/test.go1
-rw-r--r--pkg/integration/tests/demo/bisect.go1
-rw-r--r--pkg/integration/tests/demo/cherry_pick.go1
-rw-r--r--pkg/integration/tests/demo/commit_and_push.go1
-rw-r--r--pkg/integration/tests/demo/interactive_rebase.go1
-rw-r--r--pkg/integration/tests/demo/nuke_working_tree.go1
6 files changed, 5 insertions, 1 deletions
diff --git a/pkg/integration/components/test.go b/pkg/integration/components/test.go
index d24e20bd5..130ce8774 100644
--- a/pkg/integration/components/test.go
+++ b/pkg/integration/components/test.go
@@ -190,7 +190,6 @@ func (self *IntegrationTest) Run(gui integrationTypes.GuiDriver) {
// Setting caption to clear the options menu from whatever it starts with
testDriver.SetCaption("")
testDriver.SetCaptionPrefix("")
- testDriver.Wait(1000)
}
self.run(testDriver, keys)
diff --git a/pkg/integration/tests/demo/bisect.go b/pkg/integration/tests/demo/bisect.go
index b3cfe9936..b001708ea 100644
--- a/pkg/integration/tests/demo/bisect.go
+++ b/pkg/integration/tests/demo/bisect.go
@@ -28,6 +28,7 @@ var Bisect = NewIntegrationTest(NewIntegrationTestArgs{
},
Run: func(t *TestDriver, keys config.KeybindingConfig) {
t.SetCaptionPrefix("Git bisect")
+ t.Wait(1000)
markCommitAsBad := func() {
t.Views().Commits().
diff --git a/pkg/integration/tests/demo/cherry_pick.go b/pkg/integration/tests/demo/cherry_pick.go
index 5732a5b95..0dd34c8b9 100644
--- a/pkg/integration/tests/demo/cherry_pick.go
+++ b/pkg/integration/tests/demo/cherry_pick.go
@@ -32,6 +32,7 @@ var CherryPick = NewIntegrationTest(NewIntegrationTestArgs{
},
Run: func(t *TestDriver, keys config.KeybindingConfig) {
t.SetCaptionPrefix("Cherry pick commits from another branch")
+ t.Wait(1000)
t.Views().Branches().
Focus().
diff --git a/pkg/integration/tests/demo/commit_and_push.go b/pkg/integration/tests/demo/commit_and_push.go
index e897413e9..a0e196cf0 100644
--- a/pkg/integration/tests/demo/commit_and_push.go
+++ b/pkg/integration/tests/demo/commit_and_push.go
@@ -28,6 +28,7 @@ var CommitAndPush = NewIntegrationTest(NewIntegrationTestArgs{
},
Run: func(t *TestDriver, keys config.KeybindingConfig) {
t.SetCaptionPrefix("Stage a file")
+ t.Wait(1000)
t.Views().Files().
IsFocused().
diff --git a/pkg/integration/tests/demo/interactive_rebase.go b/pkg/integration/tests/demo/interactive_rebase.go
index f8889d529..fd19e3657 100644
--- a/pkg/integration/tests/demo/interactive_rebase.go
+++ b/pkg/integration/tests/demo/interactive_rebase.go
@@ -28,6 +28,7 @@ var InteractiveRebase = NewIntegrationTest(NewIntegrationTestArgs{
},
Run: func(t *TestDriver, keys config.KeybindingConfig) {
t.SetCaptionPrefix("Interactive rebase")
+ t.Wait(1000)
t.Views().Commits().
IsFocused().
diff --git a/pkg/integration/tests/demo/nuke_working_tree.go b/pkg/integration/tests/demo/nuke_working_tree.go
index d69b06879..dba670c39 100644
--- a/pkg/integration/tests/demo/nuke_working_tree.go
+++ b/pkg/integration/tests/demo/nuke_working_tree.go
@@ -28,6 +28,7 @@ var NukeWorkingTree = NewIntegrationTest(NewIntegrationTestArgs{
},
Run: func(t *TestDriver, keys config.KeybindingConfig) {
t.SetCaptionPrefix("Nuke the working tree")
+ t.Wait(1000)
t.Views().Files().
IsFocused().