Kokoro: catch more build failures.

The script should fail the build if there are any failures detected.

Change-Id: Ic4ec10adda0bf16e616dce1f0a08a85c91a0b440
diff --git a/kokoro/ubuntu/build.sh b/kokoro/ubuntu/build.sh
index a0b2c90..f15971a 100755
--- a/kokoro/ubuntu/build.sh
+++ b/kokoro/ubuntu/build.sh
@@ -2,6 +2,10 @@
 
 # Fail on any error.
 set -e
+# Fail on any part of a pipeline failing.
+set -o pipefail
+# Treat unset variables as an error.
+set -u
 # Display commands being run.
 set -x
 
diff --git a/kokoro/ubuntu/test.sh b/kokoro/ubuntu/test.sh
index 1e74335..8580712 100755
--- a/kokoro/ubuntu/test.sh
+++ b/kokoro/ubuntu/test.sh
@@ -7,7 +7,7 @@
 set -e
 # Fail on any part of a pipeline failing.
 set -o pipefail
-# Treat unset variables as an error
+# Treat unset variables as an error.
 set -u
 # Display commands being run.
 set -x