From 22eff3a83c640ed93b64bee616c2964fce5cd0c6 Mon Sep 17 00:00:00 2001
From: Jason Hiser <jdhiser@gmail.com>
Date: Tue, 3 Sep 2019 14:44:37 -0400
Subject: [PATCH] testing fuzzing

---
 cicd_testing/do-build.sh  | 19 +++++++++++++++++++
 cicd_testing/do-clean.sh  | 20 ++++++++++++++++++++
 cicd_testing/do-deploy.sh |  3 +++
 cicd_testing/do-fuzz.sh   |  5 +++++
 cicd_testing/do-test.sh   | 14 ++++++++++++++
 5 files changed, 61 insertions(+)
 create mode 100755 cicd_testing/do-build.sh
 create mode 100755 cicd_testing/do-clean.sh
 create mode 100755 cicd_testing/do-deploy.sh
 create mode 100755 cicd_testing/do-fuzz.sh
 create mode 100755 cicd_testing/do-test.sh

diff --git a/cicd_testing/do-build.sh b/cicd_testing/do-build.sh
new file mode 100755
index 0000000..a0049e3
--- /dev/null
+++ b/cicd_testing/do-build.sh
@@ -0,0 +1,19 @@
+#!/bin/bash
+set -e
+set -x
+
+
+# update submodules
+git submodule sync --recursive
+git submodule update --recursive --init
+# gather info for debugging later, probably not necessary 
+pwd
+hostname
+whoami
+env|grep CICD
+
+time rsync -a --exclude='.git'  $CICD_TO_TEST_DIR/ /tmp/libehp_test
+cd /tmp/libehp_test
+source set_env_vars
+scons -j 3
+
diff --git a/cicd_testing/do-clean.sh b/cicd_testing/do-clean.sh
new file mode 100755
index 0000000..60122df
--- /dev/null
+++ b/cicd_testing/do-clean.sh
@@ -0,0 +1,20 @@
+#!/bin/bash
+set -e
+set -x
+
+main()
+{
+
+        if [[ $CICD_NIGHTLY == 1 ]] ; then
+		# gather info for debugging later, probably not necessary 
+		pwd
+		hostname
+		whoami
+		env|grep CICD
+
+		rm -rf /tmp/libehp_test
+	fi
+}
+
+main "$@"
+
diff --git a/cicd_testing/do-deploy.sh b/cicd_testing/do-deploy.sh
new file mode 100755
index 0000000..9f11436
--- /dev/null
+++ b/cicd_testing/do-deploy.sh
@@ -0,0 +1,3 @@
+#!/bin/bash
+
+echo No deploy yet.
diff --git a/cicd_testing/do-fuzz.sh b/cicd_testing/do-fuzz.sh
new file mode 100755
index 0000000..6fab3e4
--- /dev/null
+++ b/cicd_testing/do-fuzz.sh
@@ -0,0 +1,5 @@
+#!/bin/bash 
+
+
+echo do nothing yet
+
diff --git a/cicd_testing/do-test.sh b/cicd_testing/do-test.sh
new file mode 100755
index 0000000..2ce5fd7
--- /dev/null
+++ b/cicd_testing/do-test.sh
@@ -0,0 +1,14 @@
+#!/bin/bash
+
+set -e 
+set -x
+
+
+function main()
+{
+	cd /tmp/libehp_test/test
+	./test.sh
+	exit 0
+}
+
+main "$@"
-- 
GitLab