Skip to content

Commit

Permalink
test fish_right_prompt.fish
Browse files Browse the repository at this point in the history
  • Loading branch information
edouard-lopez committed Jan 8, 2019
1 parent 92ba4af commit 4196b44
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions tests/fish_right_prompt.test.fish
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
source $DIRNAME/../fish_right_prompt.fish

set --local empty ''

test "fish_right_prompt: succeed"
(
fish_right_prompt 2>&1 >/dev/null
) $status -eq 0
end

test "fish_right_prompt: prints $pure_color_right_prompt"
(
set pure_right_prompt "🐙" # U+1F419 OCTOPUS
set pure_color_right_prompt $empty
set pure_color_normal $empty

fish_right_prompt
) = '🐙'
end

test "fish_right_prompt: prints colorful right_prompt"
(
set pure_right_prompt "🐬" # U+1F42C DOLPHIN
set pure_color_right_prompt (set_color blue)
set pure_color_normal (set_color normal)

fish_right_prompt
) = (set_color blue)'🐬'(set_color normal)
end

0 comments on commit 4196b44

Please sign in to comment.