summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorNicolas Lacasse <nlacasse@google.com>2018-12-21 17:12:28 -0800
committerShentubot <shentubot@google.com>2018-12-21 17:13:34 -0800
commitd2f8586a1f412aa69876ec9698160dcf23c6bca3 (patch)
treef19d14e2c06fbcc724cdf260f924e1e96a682944
parent7a3b4b7bdd7d1410190ab6e61a6c2e66105fa975 (diff)
Kokoro: Build all packages as part of presubmit.
We now build all packages (including //test/...) with RBE as part of the Kokoro presubmit. The tests do not yet use RBE, because there are some failures. The Golang unit, integration, and image tests still run locally. The syscall test suite needs even more work to make it pass on RBE. Those will be enabled in follow-up CLs. They currently are not enabled at all on Kokoro. PiperOrigin-RevId: 226562208 Change-Id: Idd2b81b3e8f07bf300c77e68990493ba97d16e23
-rwxr-xr-xkokoro/run_tests.sh10
-rw-r--r--test/syscalls/linux/socket_netlink_util.cc3
2 files changed, 9 insertions, 4 deletions
diff --git a/kokoro/run_tests.sh b/kokoro/run_tests.sh
index 3f9c48865..f84c9ff41 100755
--- a/kokoro/run_tests.sh
+++ b/kokoro/run_tests.sh
@@ -32,7 +32,9 @@ readonly RBE_PROJECT_ID="projects/${CLOUD_PROJECT_ID}/instances/default_instance
readonly RUNTIME="runsc_test_$((RANDOM))"
# Packages that will be built and tested.
-# TODO: Include syscall tests in "test" directory.
+readonly BUILD_PACKAGES=("//...")
+# TODO: Include syscall tests in "test" directory once all tests
+# pass on RBE.
readonly TEST_PACKAGES=("//pkg/..." "//runsc/..." "//tools/...")
#######################
@@ -76,14 +78,16 @@ build_everything() {
"${BAZEL_RBE_FLAGS[@]}" \
build \
"${BAZEL_BUILD_RBE_FLAGS[@]}" \
- "${TEST_PACKAGES[@]}"
+ "${BUILD_PACKAGES[@]}"
}
# Run simple tests runs the tests that require no special setup or
# configuration.
+# TODO: Use RBE here once tests pass with RBE.
run_simple_tests() {
cd ${WORKSPACE_DIR}
- bazel test \
+ bazel \
+ test \
"${BAZEL_BUILD_FLAGS[@]}" \
"${TEST_PACKAGES[@]}"
}
diff --git a/test/syscalls/linux/socket_netlink_util.cc b/test/syscalls/linux/socket_netlink_util.cc
index ee0e03966..edf549544 100644
--- a/test/syscalls/linux/socket_netlink_util.cc
+++ b/test/syscalls/linux/socket_netlink_util.cc
@@ -12,11 +12,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.
+#include <sys/socket.h>
+
#include <linux/if_arp.h>
#include <linux/netlink.h>
#include <linux/rtnetlink.h>
-#include <sys/socket.h>
#include <vector>
#include "absl/strings/str_cat.h"