1# To get the "command not found" message when aliasing is suppressed
2# we need, er, a command that isn't found.
3# The other aliases are only ever used as aliases.
4
5%prep
6  alias ThisCommandDefinitelyDoesNotExist=echo
7
8  alias -g bar=echo
9
10  alias '\bar=echo'
11
12%test
13  ThisCommandDefinitelyDoesNotExist ThisCommandDefinitelyDoesNotExist
140:Basic aliasing
15>ThisCommandDefinitelyDoesNotExist
16
17  bar bar
180:Global aliasing
19>echo
20
21  \ThisCommandDefinitelyDoesNotExist ThisCommandDefinitelyDoesNotExist
22127:Not aliasing
23?(eval):1: command not found: ThisCommandDefinitelyDoesNotExist
24
25  \bar \bar
260:Aliasing with a backslash
27>bar
28
29  (alias '!=echo This command has the argument'
30  eval 'print Without
31  ! true'
32  setopt posixaliases
33  eval 'print With
34  ! true')
351:POSIX_ALIASES option
36>Without
37>This command has the argument true
38>With
39
40  print -u $ZTST_fd 'This test hangs the shell when it fails...'
41  alias cat='LC_ALL=C cat'
42  cat <(echo foo | cat)
430:Alias expansion works at the end of parsed strings
44>foo
45