1 | #!/usr/bin/env bash
|
2 | #
|
3 | # Usage:
|
4 | # benchmarks/id-test.sh <function name>
|
5 |
|
6 | : ${LIB_OSH=stdlib/osh}
|
7 | source $LIB_OSH/bash-strict.sh
|
8 | source $LIB_OSH/no-quotes.sh
|
9 | source $LIB_OSH/task-five.sh
|
10 |
|
11 | source benchmarks/id.sh
|
12 | source build/dev-shell.sh # python2
|
13 |
|
14 | test-shell-prov() {
|
15 | shell-provenance-2 no-host 2022-12-29 _tmp/ \
|
16 | bin/osh
|
17 | }
|
18 |
|
19 | test-out-param() {
|
20 | local mylocal
|
21 |
|
22 | out-param mylocal
|
23 | nq-assert "$mylocal" = 'returned'
|
24 |
|
25 | echo "mylocal=$mylocal"
|
26 | }
|
27 |
|
28 | test-compiler-id() {
|
29 | dump-compiler-id $(which gcc)
|
30 |
|
31 | if test -f $CLANG; then
|
32 | dump-compiler-id $CLANG
|
33 | fi
|
34 |
|
35 | head _tmp/compiler-id/*/version.txt
|
36 | }
|
37 |
|
38 | soil-run() {
|
39 | devtools/byo.sh test $0
|
40 | }
|
41 |
|
42 | task-five "$@"
|