libfmd_agent: make fmd_agent_cpu_* visible even on 64-bit
[unleashed.git] / bin / make / unit-tests / escape.exp
blob6238e27b0191c74011becd8411c6515e4f4246f3
1 var-1bs
2 printf "%s=:%s:\n" VAR1BS 111\\111; printf "%s=:%s:\n" VAR1BSa 111\\aaa; printf "%s=:%s:\n" VAR1BSA 111\\aaa; printf "%s=:%s:\n" VAR1BSda 111\\\$\{a\}; printf "%s=:%s:\n" VAR1BSdA 111\\\$\{A\}; printf "%s=:%s:\n" VAR1BSc 111\#\ backslash\ escapes\ comment\ char,\ so\ this\ is\ part\ of\ the\ value; printf "%s=:%s:\n" VAR1BSsc 111\\\ ;
3 VAR1BS=:111\111:
4 VAR1BSa=:111\aaa:
5 VAR1BSA=:111\aaa:
6 VAR1BSda=:111\${a}:
7 VAR1BSdA=:111\${A}:
8 VAR1BSc=:111# backslash escapes comment char, so this is part of the value:
9 VAR1BSsc=:111\ :
10 var-2bs
11 printf "%s=:%s:\n" VAR2BS 222\\\\222; printf "%s=:%s:\n" VAR2BSa 222\\\\aaa; printf "%s=:%s:\n" VAR2BSA 222\\\\aaa; printf "%s=:%s:\n" VAR2BSda 222\\\\\$\{a\}; printf "%s=:%s:\n" VAR2BSdA 222\\\\\$\{A\}; printf "%s=:%s:\n" VAR2BSc 222\\\\; printf "%s=:%s:\n" VAR2BSsc 222\\\\;
12 VAR2BS=:222\\222:
13 VAR2BSa=:222\\aaa:
14 VAR2BSA=:222\\aaa:
15 VAR2BSda=:222\\${a}:
16 VAR2BSdA=:222\\${A}:
17 VAR2BSc=:222\\:
18 VAR2BSsc=:222\\:
19 var-1bsnl
20 printf "%s=:%s:\n" VAR1BSNL 111\ 111; printf "%s=:%s:\n" VAR1BSNLa 111\ aaa; printf "%s=:%s:\n" VAR1BSNLA 111\ aaa; printf "%s=:%s:\n" VAR1BSNLda 111\ \$\{a\}; printf "%s=:%s:\n" VAR1BSNLdA 111\ \$\{A\}; printf "%s=:%s:\n" VAR1BSNLc 111; printf "%s=:%s:\n" VAR1BSNLsc 111;
21 VAR1BSNL=:111 111:
22 VAR1BSNLa=:111 aaa:
23 VAR1BSNLA=:111 aaa:
24 VAR1BSNLda=:111 ${a}:
25 VAR1BSNLdA=:111 ${A}:
26 VAR1BSNLc=:111:
27 VAR1BSNLsc=:111:
28 var-2bsnl
29 printf "%s=:%s:\n" VAR2BSNL 222\\\\; printf "%s=:%s:\n" VAR2BSNLa 222\\\\; printf "%s=:%s:\n" VAR2BSNLA 222\\\\; printf "%s=:%s:\n" VAR2BSNLda 222\\\\; printf "%s=:%s:\n" VAR2BSNLdA 222\\\\; printf "%s=:%s:\n" VAR2BSNLc 222\\\\; printf "%s=:%s:\n" VAR2BSNLsc 222\\\\;
30 VAR2BSNL=:222\\:
31 VAR2BSNLa=:222\\:
32 VAR2BSNLA=:222\\:
33 VAR2BSNLda=:222\\:
34 VAR2BSNLdA=:222\\:
35 VAR2BSNLc=:222\\:
36 VAR2BSNLsc=:222\\:
37 var-3bsnl
38 printf "%s=:%s:\n" VAR3BSNL 333\\\\\ 333=; printf "%s=:%s:\n" VAR3BSNLa 333\\\\\ aaa=; printf "%s=:%s:\n" VAR3BSNLA 333\\\\\ aaa=; printf "%s=:%s:\n" VAR3BSNLda 333\\\\\ \$\{a\}=; printf "%s=:%s:\n" VAR3BSNLdA 333\\\\\ \$\{A\}=; printf "%s=:%s:\n" VAR3BSNLc 333\\\\; printf "%s=:%s:\n" VAR3BSNLsc 333\\\\;
39 VAR3BSNL=:333\\ 333=:
40 VAR3BSNLa=:333\\ aaa=:
41 VAR3BSNLA=:333\\ aaa=:
42 VAR3BSNLda=:333\\ ${a}=:
43 VAR3BSNLdA=:333\\ ${A}=:
44 VAR3BSNLc=:333\\:
45 VAR3BSNLsc=:333\\:
46 var-1bsnl-space
47 printf "%s=:%s:\n" VAR1BSNL00 first\ line; printf "%s=:%s:\n" VAR1BSNL0 first\ line\ no\ space\ on\ second\ line; printf "%s=:%s:\n" VAR1BSNLs first\ line\ one\ space\ on\ second\ line; printf "%s=:%s:\n" VAR1BSNLss first\ line\ two\ spaces\ on\ second\ line; printf "%s=:%s:\n" VAR1BSNLt first\ line\ one\ tab\ on\ second\ line; printf "%s=:%s:\n" VAR1BSNLtt first\ line\ two\ tabs\ on\ second\ line; printf "%s=:%s:\n" VAR1BSNLxx first\ line\ many\ spaces\ and\ tabs\ \[\ \ \ \ \]\ on\ second\ line;
48 VAR1BSNL00=:first line:
49 VAR1BSNL0=:first line no space on second line:
50 VAR1BSNLs=:first line one space on second line:
51 VAR1BSNLss=:first line two spaces on second line:
52 VAR1BSNLt=:first line one tab on second line:
53 VAR1BSNLtt=:first line two tabs on second line:
54 VAR1BSNLxx=:first line many spaces and tabs [ ] on second line:
55 cmd-1bsnl
56 echo :'first line\
57 #second line without space\
58 third line':
59 :first line\
60 #second line without space\
61 third line:
62 echo :'first line\
63 second line spaces should be retained':
64 :first line\
65 second line spaces should be retained:
66 echo :'first line\
67 second line tab should be elided':
68 :first line\
69 second line tab should be elided:
70 echo :'first line\
71 only one tab should be elided, second tab remains'
72 :first line\
73 only one tab should be elided, second tab remains
74 cmd-1bsnl-eof
75 echo :'command ending with backslash-newline'; \
77 :command ending with backslash-newline
78 cmd-2bsnl
79 echo take one\\
80 take one\
81 echo take two\\
82 take two\
83 echo take three\\
84 take three\
85 cmd-3bsnl
86 echo :'first line\\\
87 #second line without space\\\
88 third line':
89 :first line\\\
90 #second line without space\\\
91 third line:
92 echo :'first line\\\
93 second line spaces should be retained':
94 :first line\\\
95 second line spaces should be retained:
96 echo :'first line\\\
97 second line tab should be elided':
98 :first line\\\
99 second line tab should be elided:
100 echo :'first line\\\
101 only one tab should be elided, second tab remains'
102 :first line\\\
103 only one tab should be elided, second tab remains
104 exit status 0