From 8f62ad94da6058ac8f66a37caac518b643ccafe3 Mon Sep 17 00:00:00 2001 From: Michael Allen Date: Sun, 30 Aug 2015 19:54:40 +0100 Subject: Test the zsh color changes configuration --- test-colors.sh | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'test-colors.sh') diff --git a/test-colors.sh b/test-colors.sh index 6b8a797..73aac53 100755 --- a/test-colors.sh +++ b/test-colors.sh @@ -173,4 +173,22 @@ test_zsh_colors_remote() { rm_tmp } +test_zsh_colors_changes() { + set_zsh_env_vars + prepare_zsh_colors + + cd_to_tmp + git init --quiet + + touch foo + touch bar + git add bar + echo "bar" > bar + untracked="1%{changes-untracked%}A%{change-reset%}" + unstaged="1%{changes-unstaged%}M%{change-reset%}" + staged="1%{changes-staged%}A%{change-reset%}" + + assertEquals " $staged $unstaged $untracked" "$(zsh_color_changes_status)" +} + . ./shunit/shunit2 -- cgit v1.2.3