aboutsummaryrefslogtreecommitdiffstats
path: root/test/arguments/symrun.sh
blob: d28f024a83a968ca71233ea56c94eabdc84f6e3e (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
28
29
30
#!/bin/bash

mkdir symtest
ln -s /usr/bin/firejail symtest/argtest

# search for argtest in current directory
export PATH=$PATH:.

echo "TESTING: 2.1 - simple args"
symtest/argtest arg1 arg2

# simple quotes, testing spaces in file names
echo "TESTING: 2.2 - args with space and \""
symtest/argtest "arg1 tail" "arg2 tail"

echo "TESTING: 2.3 - args with space and '"
symtest/argtest 'arg1 tail' 'arg2 tail'

# escaped space in file names
echo "TESTING: 2.4 - args with space and \\"
symtest/argtest arg1\ tail arg2\ tail

# & char appears in URLs - URLs should be quoted
echo "TESTING: 2.5 - args with & and \""
symtest/argtest "arg1&tail" "arg2&tail"

echo "TESTING: 2.6 - args with & and '"
symtest/argtest 'arg1&tail' 'arg2&tail'

rm -fr symtest