bash-it search functionality: allow test to skip on travis

This commit is contained in:
Konstantin Gredeskoul
2016-03-23 23:26:13 -07:00
parent c0a657270c
commit a9bf098c7a

View File

@@ -8,12 +8,14 @@ cite _about _param _example _group _author _version
load ../../lib/helpers
NO_COLOR=true
IS_DARWIN=false
IS_DARWIN=
[[ "$(uname -s)" == "Darwin" ]] && IS_DARWIN=true
if [ "$IS_DARWIN" == "true" ]; then
@test "helpers search aliases" {
run _bash-it-search-component 'plugins' 'base'
[[ "${lines[0]}" =~ 'plugins' && "${lines[0]}" =~ 'base' ]]
}
fi
@test "helpers search aliases" {
if [ -z "$IS_DARWIN" ]; then
skip 'search test only runs on OSX'
fi
run _bash-it-search-component 'plugins' 'base'
[[ "${lines[0]}" =~ 'plugins' && "${lines[0]}" =~ 'base' ]]
}