mirror of
https://github.com/zsh-users/zsh-autosuggestions.git
synced 2024-05-11 05:54:57 +00:00
Refactor to remove prev cmd function and simplify escaping
This commit is contained in:
@@ -43,30 +43,4 @@ testEscapeCommand() {
|
||||
"$(_zsh_autosuggest_escape_command '?')"
|
||||
}
|
||||
|
||||
testPrevCommand() {
|
||||
set_history <<-'EOF'
|
||||
ls foo
|
||||
ls bar
|
||||
ls baz
|
||||
EOF
|
||||
|
||||
assertEquals \
|
||||
'Did not output the last command' \
|
||||
'ls baz' \
|
||||
"$(_zsh_autosuggest_prev_command)"
|
||||
|
||||
set_history <<-'EOF'
|
||||
ls foo
|
||||
ls bar
|
||||
ls baz
|
||||
ls quux
|
||||
ls foobar
|
||||
EOF
|
||||
|
||||
assertEquals \
|
||||
'Did not output the last command' \
|
||||
'ls foobar' \
|
||||
"$(_zsh_autosuggest_prev_command)"
|
||||
}
|
||||
|
||||
run_tests "$0"
|
||||
|
||||
Reference in New Issue
Block a user