These tests are based on the patches contributed in those issues:
commit 9d9df4fe80 (upstream/pr/167)
Author: Miciah Masters <miciah.masters@gmail.com>
AuthorDate: Thu Apr 23 20:28:24 2015 -0400
Commit: Miciah Dashiel Butler Masters <mmasters@redhat.com>
CommitDate: Thu Apr 23 20:28:24 2015 -0400
Highlight comments
M highlighters/main/main-highlighter.zsh
A highlighters/main/test-data/comments.zsh
commit d94f1a037f (upstream/pr/163)
Author: sonnym <michaud.sonny@gmail.com>
AuthorDate: Fri Mar 6 18:27:57 2015 -0500
Commit: sonnym <michaud.sonny@gmail.com>
CommitDate: Fri Mar 6 21:16:27 2015 -0500
highlight comments when interactive_comments is on
M highlighters/main/main-highlighter.zsh
A highlighters/main/test-data/comment-embedded.zsh
A highlighters/main/test-data/comment-leading.zsh
Patch-by: sonnym <michaud.sonny@gmail.com>
Patch-by: Miciah Masters <miciah.masters@gmail.com>
(corrected and refreshed for harness changes by me)
The change of behaviour is triggered by test-data/sudo-redirection.zsh: the iteration
on "otheruser" sets $next_word to ":regular::sudo_opt::start::sudo_opt::start:" before
this patch, but to ":regular::sudo_opt::start:" after it (note the deduplication).
The fix for issue #9 was accidentally broken by the penultimate commit.
Note that we don't care about aliases to ZSH_HIGHLIGHT_TOKENS_COMMANDSEPARATOR
entries, since the code deals with aliases at command position.
Use this to remove [path_prefix] highlighting during accept-* widgets.
This causes ": file.tx<CR>" to remove the underline from "file.tx", like
": file.tx<SPACE>" already does. (Assume 'file.txt' exists.)
It's the widget's caller's responsibility, not ours, to add '--' where due. If
we do it, two instances of '--' might result. (I haven't been able to provoke
this problem.)
If this commit causes problems, the cause would be widget-callers that don't
pass '--' although they should.
test failure would not be reflected by the exit code of 'make'.
Setting a shell parameter in the left-hand side of a pipe is not visible to
commands after the pipe, because the left-hand side forks. (That's true both
in 'sh' used by 'make' and in 'zsh' that runs tests/test-highlighting.zsh, at
least on my system.) Therefore, move the colorizing hook to where it doesn't
interfere with setting the $something_failed (in tests/test-highlighting.zsh)
and $result (in Makefile) parameters.