mirror of
https://github.com/ddworken/hishtory.git
synced 2025-01-23 06:38:52 +01:00
Add test for beta-mode enabling highlighting of matching queries
This commit is contained in:
parent
e04583f62f
commit
83c3664de6
@ -1659,6 +1659,13 @@ func testTui_color(t testing.TB) {
|
||||
out = captureTerminalOutputComplex(t, tester, tester.ShellName(), 200, 50, []TmuxCommand{{Keys: "hishtory SPACE tquery ENTER"}, {Keys: "ech"}}, true)
|
||||
out = strings.TrimSpace(strings.Split(out, "hishtory tquery")[1])
|
||||
testutils.CompareGoldens(t, out, "TestTui-ColoredOutputWithSearch")
|
||||
|
||||
// And one more time with beta-mode for highlighting matches
|
||||
tester.RunInteractiveShell(t, ` hishtory config-set beta-mode true`)
|
||||
require.Equal(t, "true", strings.TrimSpace(tester.RunInteractiveShell(t, `hishtory config-get beta-mode`)))
|
||||
out = captureTerminalOutputComplex(t, tester, tester.ShellName(), 200, 50, []TmuxCommand{{Keys: "hishtory SPACE tquery ENTER"}, {Keys: "ech"}}, true)
|
||||
out = strings.TrimSpace(strings.Split(out, "hishtory tquery")[1])
|
||||
testutils.CompareGoldens(t, out, "TestTui-ColoredOutputWithSearch-BetaMode")
|
||||
}
|
||||
|
||||
func testTui_delete(t testing.TB) {
|
||||
|
Loading…
Reference in New Issue
Block a user