summaryrefslogtreecommitdiffstats
path: root/jjb/tldk/include-raw-csit-tldk-functional-virl.sh
blob: 0192a125b5bb5d8a9bd345bbda81558476fd4a56 (plain)
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
31
32
33
34
35
36
#!/bin/bash
set -xeu -o pipefail

# Clone tldk and start tests
git clone https://gerrit.fd.io/r/tldk

# If the git clone fails, complain clearly and exit
if [ $? != 0 ]; then
    echo "Failed to run: git clone https://gerrit.fd.io/r/tldk"
    exit 1
fi

# Clone csit and start tests
git clone https://gerrit.fd.io/r/csit

# If the git clone fails, complain clearly and exit
if [ $? != 0 ]; then
    echo "Failed to run: git clone https://gerrit.fd.io/r/csit"
    exit 1
fi

cd csit

# execute nsh_sfc bootstrap script if it exists
if [ -e bootstrap-TLDK.sh ]
then
    # make sure that bootstrap-TLDK.sh is executable
    chmod +x bootstrap-TLDK.sh
    # run the script
    ./bootstrap-TLDK.sh
else
    echo 'ERROR: No bootstrap-TLDK.sh found'
    exit 1
fi

# vim: ts=4 ts=4 sts=4 et :