aboutsummaryrefslogtreecommitdiff
path: root/src/core/test_core_start_testcase.sh
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/test_core_start_testcase.sh')
-rwxr-xr-xsrc/core/test_core_start_testcase.sh15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/core/test_core_start_testcase.sh b/src/core/test_core_start_testcase.sh
new file mode 100755
index 000000000..78e67dbf5
--- /dev/null
+++ b/src/core/test_core_start_testcase.sh
@@ -0,0 +1,15 @@
1#!/bin/bash
2echo gaga1 > gaga.txt
3read -p "Test case configuration to use:" conf
4if ! [ -d "/run/netns" ]; then
5 echo You have to create the directory /run/netns.
6fi
7if [ -f /proc/sys/kernel/unprivileged_userns_clone ]; then
8 if [ "$(cat /proc/sys/kernel/unprivileged_userns_clone)" != 1 ]; then
9 echo -e "Error during test setup: The kernel parameter kernel.unprivileged_userns_clone has to be set to 1! One has to execute\n\n sysctl kernel.unprivileged_userns_clone=1\n"
10 exit 78
11 fi
12fi
13echo gaga2 >> gaga.txt
14exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; /usr/local/lib/gnunet/libexec/test_testing_start_with_config $conf"
15echo gaga3 >> gaga.txt