METRON-2018 Update prepare-commit to add Bro plugin tests (ottobackwards) closes apache/metron#1348
diff --git a/dev-utilities/committer-utils/metron-committer-common b/dev-utilities/committer-utils/metron-committer-common
index 4855254..257bcb0 100644
--- a/dev-utilities/committer-utils/metron-committer-common
+++ b/dev-utilities/committer-utils/metron-committer-common
@@ -343,8 +343,18 @@
         run_mvn_build_rpms
 
         verify_licenses
+
       elif [[ "${UPSTREAM}" == "${BRO_PLUGIN_UPSTREAM}" ]]; then
-        echo "We don't currently support running metron-bro-plugin-kafka tests in this script"
+        echo "  please verify that no bro docker containers are running before continuing,"
+        read -p "  no bro docker containers are running, ready to proceed [yN] " -n 1 -r
+        echo
+        if [[ $REPLY =~ ^[Yy]$ ]]; then
+            run_bro_docker
+            finish_bro_docker
+        else
+            echo "  when you are ready and the containers are stopped, please cd into the docker"
+            echo "  directory and execute the run_end_to_end.sh script"
+        fi
       fi
     fi
 
@@ -435,6 +445,35 @@
 }
 
 #
+#  runs the bro kafka plugin's docker based tests
+#
+function run_bro_docker {
+    cd docker &> /dev/null || { echo "failed to change directory to docker" ; exit 1; }
+    ./run_end_to_end.sh
+
+    rc=$?; if [[ ${rc} != 0 ]]; then
+        echo "ERROR> FAILED run_end_to_end"
+        # do NOT exit here
+    fi
+    cd .. &> /dev/null || { echo "failed to change directory to plugin root"; exit 1; }
+}
+
+#
+#   runs the finish bro docker script to cleanup
+#
+function finish_bro_docker {
+    cd docker &> /dev/null || { echo "failed to change directory to docker"; exit 1; }
+    ./finish_end_to_end.sh
+
+    rc=$?; if [[ ${rc} != 0 ]]; then
+        echo "ERROR> FAILED finish_end_to_end"
+        exit ${rc}
+    fi
+    cd .. &> /dev/null || { echo "failed to change directory to plugin root";
+        exit 1; }
+}
+
+#
 # verifies licenses using our script
 #
 function verify_licenses {
@@ -455,4 +494,4 @@
     echo "    cd $WORK"
     echo "    git push upstream $BASE_BRANCH"
     echo ""
-}
\ No newline at end of file
+}