about summary refs log tree commit diff
path: root/Test/A02alias.ztst
blob: 0c2a464c991bc5c3fee212067399c3f0a3da1500 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# To get the "command not found" message when aliasing is suppressed
# we need, er, a command that isn't found.
# The other aliases are only ever used as aliases.

%prep
  alias ThisCommandDefinitelyDoesNotExist=echo

  alias -g bar=echo

  alias '\bar=echo'

%test
  ThisCommandDefinitelyDoesNotExist ThisCommandDefinitelyDoesNotExist
0:Basic aliasing
>ThisCommandDefinitelyDoesNotExist

  bar bar
0:Global aliasing
>echo

  \ThisCommandDefinitelyDoesNotExist ThisCommandDefinitelyDoesNotExist
127:Not aliasing
?(eval):1: command not found: ThisCommandDefinitelyDoesNotExist

  \bar \bar
0:Aliasing with a backslash
>bar