Skip to content

Commit 779e6f9

Browse files
committed
Assert that the search status view is visible
Just to be really sure that it not only contains the expected status text, but also actually shows it.
1 parent 44ad36b commit 779e6f9

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

pkg/integration/tests/commit/search.go

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ var Search = NewIntegrationTest(NewIntegrationTestArgs{
3131
Type("two").
3232
Confirm()
3333

34-
t.Views().Search().Content(Contains("matches for 'two' (1 of 1)"))
34+
t.Views().Search().IsVisible().Content(Contains("matches for 'two' (1 of 1)"))
3535
}).
3636
Lines(
3737
Contains("four"),
@@ -46,7 +46,7 @@ var Search = NewIntegrationTest(NewIntegrationTestArgs{
4646
Type("o").
4747
Confirm()
4848

49-
t.Views().Search().Content(Contains("matches for 'o' (2 of 3)"))
49+
t.Views().Search().IsVisible().Content(Contains("matches for 'o' (2 of 3)"))
5050
}).
5151
Lines(
5252
Contains("four"),
@@ -56,7 +56,7 @@ var Search = NewIntegrationTest(NewIntegrationTestArgs{
5656
).
5757
Press("n").
5858
Tap(func() {
59-
t.Views().Search().Content(Contains("matches for 'o' (3 of 3)"))
59+
t.Views().Search().IsVisible().Content(Contains("matches for 'o' (3 of 3)"))
6060
}).
6161
Lines(
6262
Contains("four"),
@@ -66,7 +66,7 @@ var Search = NewIntegrationTest(NewIntegrationTestArgs{
6666
).
6767
Press("n").
6868
Tap(func() {
69-
t.Views().Search().Content(Contains("matches for 'o' (1 of 3)"))
69+
t.Views().Search().IsVisible().Content(Contains("matches for 'o' (1 of 3)"))
7070
}).
7171
Lines(
7272
Contains("four").IsSelected(),
@@ -76,7 +76,7 @@ var Search = NewIntegrationTest(NewIntegrationTestArgs{
7676
).
7777
Press("n").
7878
Tap(func() {
79-
t.Views().Search().Content(Contains("matches for 'o' (2 of 3)"))
79+
t.Views().Search().IsVisible().Content(Contains("matches for 'o' (2 of 3)"))
8080
}).
8181
Lines(
8282
Contains("four"),
@@ -86,7 +86,7 @@ var Search = NewIntegrationTest(NewIntegrationTestArgs{
8686
).
8787
Press("N").
8888
Tap(func() {
89-
t.Views().Search().Content(Contains("matches for 'o' (1 of 3)"))
89+
t.Views().Search().IsVisible().Content(Contains("matches for 'o' (1 of 3)"))
9090
}).
9191
Lines(
9292
Contains("four").IsSelected(),
@@ -96,7 +96,7 @@ var Search = NewIntegrationTest(NewIntegrationTestArgs{
9696
).
9797
Press("N").
9898
Tap(func() {
99-
t.Views().Search().Content(Contains("matches for 'o' (3 of 3)"))
99+
t.Views().Search().IsVisible().Content(Contains("matches for 'o' (3 of 3)"))
100100
}).
101101
Lines(
102102
Contains("four"),

pkg/integration/tests/staging/search.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ var Search = NewIntegrationTest(NewIntegrationTestArgs{
2929
Type("four").
3030
Confirm()
3131

32-
t.Views().Search().Content(Contains("matches for 'four' (1 of 1)"))
32+
t.Views().Search().IsVisible().Content(Contains("matches for 'four' (1 of 1)"))
3333
}).
3434
SelectedLine(Contains("+four")). // stage the line
3535
PressPrimaryAction().

0 commit comments

Comments
 (0)