diff options
author | Ben Hilburn <bhilburn@gmail.com> | 2018-11-12 18:44:23 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-11-12 18:44:23 +0300 |
commit | c7d8ef07b76b9dc6022c656c761b6422ce919e94 (patch) | |
tree | c9ce6eba19adeeaaaa1a0f9a7d40986d71e6229e /test | |
parent | 78df520772135b7924d6fc84f2bdbde0f1c650b2 (diff) | |
parent | 6cfe8f8d965bfb6a1314b907e4ab970dd42d4188 (diff) |
Merge pull request #1061 from dritter/speedup_vcs4_master
Backport of vcs-speedup #4 into master.
Diffstat (limited to 'test')
-rwxr-xr-x | test/segments/vcs-git.spec | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/test/segments/vcs-git.spec b/test/segments/vcs-git.spec index fed1df19..17a277fb 100755 --- a/test/segments/vcs-git.spec +++ b/test/segments/vcs-git.spec @@ -473,4 +473,21 @@ function testDetectingUntrackedFilesInNestedSubmodulesWork() { assertEquals "%K{002} %F{000} master ? %k%F{002}%f " "$(build_left_prompt)" } -source shunit2/shunit2
\ No newline at end of file +function testDetectingUntrackedFilesInCleanSubdirectoryWorks() { + local -a POWERLEVEL9K_LEFT_PROMPT_ELEMENTS + POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(vcs) + local POWERLEVEL9K_VCS_SHOW_SUBMODULE_DIRTY="true" + unset POWERLEVEL9K_VCS_UNTRACKED_BACKGROUND + mkdir clean-folder + touch clean-folder/file.txt + mkdir dirty-folder + touch dirty-folder/file.txt + git add . 2>/dev/null + git commit -m "Initial commit" >/dev/null + touch dirty-folder/new-file.txt + cd clean-folder + source ${P9K_HOME}/powerlevel9k.zsh-theme + assertEquals "%K{002} %F{000} master ? %k%F{002}%f " "$(build_left_prompt)" +} + +source shunit2/shunit2 |