Fix handling of changed up-to-date msg from Git (#724)

The msg was changed from 'Already up-to-date' to 'Already up to date'.
This commit is contained in:
Daniel Hahler
2018-03-04 05:43:13 +01:00
committed by Junegunn Choi
parent 96375cb7d3
commit e6a775e0df
3 changed files with 13 additions and 12 deletions

View File

@@ -37,9 +37,10 @@ Execute (Initialize test environment):
g/^$/d
endfunction
function! AssertExpect(bang, pat, cnt)
function! AssertExpect(bang, pat, cnt, ...)
let op = a:bang ? '==#' : '=~#'
AssertEqual a:cnt, len(filter(getline(1, '$'), "v:val ".op." '".a:pat."'"))
let args = [a:cnt, len(filter(getline(1, '$'), "v:val ".op." '".a:pat."'"))] + a:000
call call('vader#assert#equal', args)
endfunction
command! -nargs=+ -bang AssertExpect call AssertExpect('<bang>' == '!', <args>)