diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2023-06-03 15:50:20 +1000 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2023-06-03 15:54:03 +1000 |
commit | a9ae5063c2e6dd7d0dd3f0e6617c4abadd08fe92 (patch) | |
tree | fe518727b52fdeb5f6e63283902d8204f0c0485b | |
parent | 1932c2366b1cc8bfca634274a1e265ce795e79da (diff) |
Fix flakey test
Whenever we perform an action in a test, we should assert on the result before doing the next action.
This prevents issues where the test moves too fast for our code. It would be nice to not have to do this,
but for now that's the situation
-rw-r--r-- | pkg/integration/tests/reflog/patch.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/pkg/integration/tests/reflog/patch.go b/pkg/integration/tests/reflog/patch.go index 7cbdcba83..415fb18ee 100644 --- a/pkg/integration/tests/reflog/patch.go +++ b/pkg/integration/tests/reflog/patch.go @@ -28,6 +28,12 @@ var Patch = NewIntegrationTest(NewIntegrationTestArgs{ Contains("commit (initial): one"), ). SelectNextItem(). + Lines( + Contains("reset: moving to HEAD^^"), + Contains("commit: three").IsSelected(), + Contains("commit: two"), + Contains("commit (initial): one"), + ). PressEnter() t.Views().SubCommits(). |