Enable/Disable with negated search feature
This commit is contained in:
@@ -17,7 +17,16 @@ NO_COLOR=true
|
||||
|
||||
@test "helpers search all ruby et al" {
|
||||
run _bash-it-search 'ruby' 'gem' 'bundle' 'rake' 'rails'
|
||||
[[ "${lines[0]/\*/}" == 'aliases : bundler rails' ]]
|
||||
[[ "${lines[1]/\*/}" == 'plugins : chruby chruby-auto ruby' ]]
|
||||
[[ "${lines[2]/\*/}" == 'completions : bundler gem rake' ]]
|
||||
[[ "${lines[0]/✓/}" == ' aliases => bundler rails' ]]
|
||||
[[ "${lines[1]/✓/}" == ' plugins => chruby chruby-auto ruby' ]]
|
||||
[[ "${lines[2]/✓/}" == ' completions => bundler gem rake' ]]
|
||||
}
|
||||
|
||||
@test "search enable and disable" {
|
||||
run _bash-it-search 'ruby' 'gem' 'bundle' 'rake' 'rails' '--disable'
|
||||
run _enable-alias 'rails'
|
||||
run _bash-it-search 'ruby' 'gem' 'bundle' 'rake' 'rails'
|
||||
[[ "${lines[0]}" == ' aliases => bundler ✓rails' ]]
|
||||
[[ "${lines[1]}" == ' plugins => chruby chruby-auto ruby' ]]
|
||||
[[ "${lines[2]}" == ' completions => bundler gem rake' ]]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user