mirror of
https://github.com/ddworken/hishtory.git
synced 2025-06-20 20:07:52 +02:00
Revert "Increase delays for testTui/search since it is the flakiest test" since I figured out the source of the flakes
This reverts commit 10851528bca0194f09f2b74c4f4c87f6f484fccf.
This commit is contained in:
parent
590c4755b5
commit
bb96164ea8
@ -1791,9 +1791,9 @@ func testTui_search(t *testing.T) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Check the output when there is a search
|
// Check the output when there is a search
|
||||||
out = captureTerminalOutputWithComplexCommands(t, tester, []TmuxCommand{
|
out = captureTerminalOutput(t, tester, []string{
|
||||||
{Keys: "hishtory SPACE tquery ENTER"},
|
"hishtory SPACE tquery ENTER",
|
||||||
{Keys: "ls", ExtraDelay: 1.5},
|
"ls",
|
||||||
})
|
})
|
||||||
out = strings.TrimSpace(strings.Split(out, "hishtory tquery")[1])
|
out = strings.TrimSpace(strings.Split(out, "hishtory tquery")[1])
|
||||||
testutils.CompareGoldens(t, out, "TestTui-Search")
|
testutils.CompareGoldens(t, out, "TestTui-Search")
|
||||||
@ -1802,7 +1802,7 @@ func testTui_search(t *testing.T) {
|
|||||||
out = captureTerminalOutputWithComplexCommands(t, tester, []TmuxCommand{
|
out = captureTerminalOutputWithComplexCommands(t, tester, []TmuxCommand{
|
||||||
{Keys: "hishtory SPACE tquery ENTER"},
|
{Keys: "hishtory SPACE tquery ENTER"},
|
||||||
// Extra delay to ensure that the search for 'ls' finishes before we select an entry
|
// Extra delay to ensure that the search for 'ls' finishes before we select an entry
|
||||||
{Keys: "ls", ExtraDelay: 3.0},
|
{Keys: "ls", ExtraDelay: 2.0},
|
||||||
{Keys: "ENTER"},
|
{Keys: "ENTER"},
|
||||||
})
|
})
|
||||||
out = strings.Split(strings.TrimSpace(strings.Split(out, "hishtory tquery")[1]), "\n")[0]
|
out = strings.Split(strings.TrimSpace(strings.Split(out, "hishtory tquery")[1]), "\n")[0]
|
||||||
@ -1815,7 +1815,7 @@ func testTui_search(t *testing.T) {
|
|||||||
out = captureTerminalOutputWithComplexCommands(t, tester, []TmuxCommand{
|
out = captureTerminalOutputWithComplexCommands(t, tester, []TmuxCommand{
|
||||||
// ExtraDelay to ensure that after searching for 'foo:' it gets the real results for an empty query
|
// ExtraDelay to ensure that after searching for 'foo:' it gets the real results for an empty query
|
||||||
{Keys: "hishtory SPACE tquery SPACE foo: ENTER", ExtraDelay: 1.5},
|
{Keys: "hishtory SPACE tquery SPACE foo: ENTER", ExtraDelay: 1.5},
|
||||||
{Keys: "ls", ExtraDelay: 1.5},
|
{Keys: "ls", ExtraDelay: 1.0},
|
||||||
})
|
})
|
||||||
out = strings.TrimSpace(strings.Split(out, "hishtory tquery")[1])
|
out = strings.TrimSpace(strings.Split(out, "hishtory tquery")[1])
|
||||||
testutils.CompareGoldens(t, out, "TestTui-InitialInvalidSearch")
|
testutils.CompareGoldens(t, out, "TestTui-InitialInvalidSearch")
|
||||||
@ -1824,7 +1824,7 @@ func testTui_search(t *testing.T) {
|
|||||||
out = captureTerminalOutputWithComplexCommands(t, tester, []TmuxCommand{
|
out = captureTerminalOutputWithComplexCommands(t, tester, []TmuxCommand{
|
||||||
{Keys: "hishtory SPACE tquery ENTER", ExtraDelay: 1.0},
|
{Keys: "hishtory SPACE tquery ENTER", ExtraDelay: 1.0},
|
||||||
// ExtraDelay to ensure that the search for 'ls' finishes before we make it invalid by adding ':'
|
// ExtraDelay to ensure that the search for 'ls' finishes before we make it invalid by adding ':'
|
||||||
{Keys: "ls", ExtraDelay: 3.0},
|
{Keys: "ls", ExtraDelay: 1.5},
|
||||||
{Keys: ":"},
|
{Keys: ":"},
|
||||||
})
|
})
|
||||||
out = strings.TrimSpace(strings.Split(out, "hishtory tquery")[1])
|
out = strings.TrimSpace(strings.Split(out, "hishtory tquery")[1])
|
||||||
|
Loading…
x
Reference in New Issue
Block a user