mirror of
https://github.com/zsh-users/zsh-syntax-highlighting.git
synced 2025-12-04 21:56:45 +01:00
tests: Use $unused_highlight in more places.
Notably, the 'single-hyphen-option' and 'assign' contexts both default to the 'none' style, so before this patch, the tests would not have detected a failure to apply those two contexts. For other contexts, using $unused_highlight only helps detect the case where the right highlight style (e.g., 'fg=yellow') is used as a result of applying the wrong context — which should be a theoretical failure mode. This is part of zsh-users/zsh-syntax-highlighting#198.
This commit is contained in:
parent
00862cf4fa
commit
627eb71940
5 changed files with 5 additions and 0 deletions
|
|
@ -28,6 +28,7 @@
|
|||
# vim: ft=zsh sw=2 ts=2 et
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
ZSH_HIGHLIGHT_STYLES[single-hyphen-option]=$unused_highlight
|
||||
BUFFER='sudo -u otheruser ls /'
|
||||
|
||||
expected_region_highlight=(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue