File: builder-invalid-script.test.sh

package info (click to toggle)
keyman 18.0.246-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 21,316 kB
  • sloc: python: 52,784; cpp: 21,289; sh: 7,633; ansic: 4,823; xml: 3,617; perl: 959; makefile: 139; javascript: 138
file content (27 lines) | stat: -rwxr-xr-x 670 bytes parent folder | download | duplicates (2)
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
#!/usr/bin/env bash

echo "Testing missing builder_describe"
./builder-invalid-script-1.test.sh
RES=$?
if [[ $RES -ne 1 ]]; then
  echo "ERROR: expected builder-invalid-script-1.test.sh to exit with code 1 but instead got $RES"
  exit 1
fi

echo "Testing missing builder_parse"
./builder-invalid-script-2.test.sh
RES=$?
if [[ $RES -ne 1 ]]; then
  echo "ERROR: expected builder-invalid-script-2.test.sh to exit with code 1 but instead got $RES"
  exit 2
fi

echo "Testing base case"
./builder-invalid-script-3.test.sh
RES=$?
if [[ $RES -ne 0 ]]; then
  echo "ERROR: expected builder-invalid-script-3.test.sh to exit with code 0 but instead got $RES"
  exit 3
fi

exit 0