File: test-examples.sh

package info (click to toggle)
datatype99 1.6.5-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 460 kB
  • sloc: ansic: 1,071; sh: 43; makefile: 6
file content (26 lines) | stat: -rwxr-xr-x 483 bytes parent folder | download | duplicates (3)
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
#!/bin/bash

set -e

mkdir -p examples/build
cd examples/build
cmake ..
cmake --build .

run_example() {
    echo "executing ./$1 ..."
    ./$1
}

if [[ "$OSTYPE" == "linux-gnu" ]]; then
    run_example "array_in_variant"
    run_example "ast"
    run_example "binary_tree_malloc"
    run_example "binary_tree"
    run_example "token"

    run_example "derive/metadata"
    run_example "derive/record_metadata"
    run_example "derive/print"
    run_example "derive/command_menu"
fi