summaryrefslogtreecommitdiffstats
path: root/pkg/integration/tests/commit/unstaged.go
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/integration/tests/commit/unstaged.go')
-rw-r--r--pkg/integration/tests/commit/unstaged.go24
1 files changed, 12 insertions, 12 deletions
diff --git a/pkg/integration/tests/commit/unstaged.go b/pkg/integration/tests/commit/unstaged.go
index 2d6ba8b8a..69eb4e814 100644
--- a/pkg/integration/tests/commit/unstaged.go
+++ b/pkg/integration/tests/commit/unstaged.go
@@ -5,7 +5,7 @@ import (
. "github.com/jesseduffield/lazygit/pkg/integration/components"
)
-// TODO: find out why we can't use input.SelectedLine() on the staging/stagingSecondary views.
+// TODO: find out why we can't use .SelectedLine() on the staging/stagingSecondary views.
var Unstaged = NewIntegrationTest(NewIntegrationTestArgs{
Description: "Staging a couple files, going in the unstaged files menu, staging a line and committing",
@@ -17,33 +17,33 @@ var Unstaged = NewIntegrationTest(NewIntegrationTestArgs{
CreateFile("myfile", "myfile content\nwith a second line").
CreateFile("myfile2", "myfile2 content")
},
- Run: func(shell *Shell, input *Input, keys config.KeybindingConfig) {
- input.Model().CommitCount(0)
+ Run: func(shell *Shell, t *TestDriver, keys config.KeybindingConfig) {
+ t.Model().CommitCount(0)
- input.Views().Files().
+ t.Views().Files().
IsFocused().
SelectedLine(Contains("myfile")).
PressEnter()
- input.Views().Staging().
+ t.Views().Staging().
IsFocused().
Tap(func() {
- input.Views().StagingSecondary().Content(DoesNotContain("+myfile content"))
+ t.Views().StagingSecondary().Content(DoesNotContain("+myfile content"))
}).
// stage the first line
PressPrimaryAction().
Tap(func() {
- input.Views().Staging().Content(DoesNotContain("+myfile content"))
- input.Views().StagingSecondary().Content(Contains("+myfile content"))
+ t.Views().Staging().Content(DoesNotContain("+myfile content"))
+ t.Views().StagingSecondary().Content(Contains("+myfile content"))
}).
Press(keys.Files.CommitChanges)
commitMessage := "my commit message"
- input.ExpectCommitMessagePanel().Type(commitMessage).Confirm()
+ t.ExpectCommitMessagePanel().Type(commitMessage).Confirm()
- input.Model().CommitCount(1)
- input.Model().HeadCommitMessage(Equals(commitMessage))
- input.Views().Staging().IsFocused()
+ t.Model().CommitCount(1)
+ t.Model().HeadCommitMessage(Equals(commitMessage))
+ t.Views().Staging().IsFocused()
// TODO: assert that the staging panel has been refreshed (it currently does not get correctly refreshed)
},