Snap for 7249665 from 72908478e1504af5f38b2e7dc9c541f38c4f62a4 to sc-release
Change-Id: I3b6290b498ff1f41b9c75f5eb8f0343a9f859335
diff --git a/Makefile b/Makefile
index c13c099..b7022b5 100644
--- a/Makefile
+++ b/Makefile
@@ -199,7 +199,7 @@
ifeq ($(USE_SYSTEM_GTEST),no)
# Points to the root of Google Test, relative to where this file is.
# Remember to tweak this if you move this file.
-GTEST_DIR = googletest-release-1.8.0/googletest
+GTEST_DIR = googletest-release-1.10.0/googletest
# Flags passed to the preprocessor.
# Set Google Test's header directory as a system directory, such that
diff --git a/get_googletest.sh b/get_googletest.sh
index 1708dcb..b379441 100755
--- a/get_googletest.sh
+++ b/get_googletest.sh
@@ -1,6 +1,6 @@
#/bin/bash
-PV="1.8.0"
+PV="1.10.0"
wget -q -nc --secure-protocol=TLSv1 "https://github.com/google/googletest/archive/release-${PV}.tar.gz" -O "googletest-release-${PV}.tar.gz"
tar zxvf "googletest-release-${PV}.tar.gz"
diff --git a/libminijail_unittest.cc b/libminijail_unittest.cc
index 1d2f76b..521982f 100644
--- a/libminijail_unittest.cc
+++ b/libminijail_unittest.cc
@@ -472,10 +472,8 @@
TEST(Test, minijail_run_env_pid_pipes) {
// TODO(crbug.com/895875): The preload library interferes with ASan since they
// both need to use LD_PRELOAD.
- if (running_with_asan()) {
- SUCCEED();
- return;
- }
+ if (running_with_asan())
+ GTEST_SKIP();
ScopedMinijail j(minijail_new());
minijail_set_preload_path(j.get(), kPreloadPath);
@@ -537,10 +535,8 @@
TEST(Test, minijail_run_env_pid_pipes_with_local_preload) {
// TODO(crbug.com/895875): The preload library interferes with ASan since they
// both need to use LD_PRELOAD.
- if (running_with_asan()) {
- SUCCEED();
- return;
- }
+ if (running_with_asan())
+ GTEST_SKIP();
ScopedMinijail j(minijail_new());
@@ -867,10 +863,8 @@
constexpr uid_t kTargetUid = 1000; // Any non-zero value will do.
constexpr gid_t kTargetGid = 1000;
- if (!userns_supported_) {
- SUCCEED();
- return;
- }
+ if (!userns_supported_)
+ GTEST_SKIP();
struct minijail *j = minijail_new();
@@ -907,10 +901,8 @@
// TODO(crbug.com/895875): The preload library interferes with ASan since they
// both need to use LD_PRELOAD.
- if (!userns_supported_ || running_with_asan()) {
- SUCCEED();
- return;
- }
+ if (!userns_supported_ || running_with_asan())
+ GTEST_SKIP();
std::string uidmap = "0 " + std::to_string(getuid()) + " 1";
std::string gidmap = "0 " + std::to_string(getgid()) + " 1";
@@ -992,10 +984,8 @@
TEST_F(NamespaceTest, test_enter_ns) {
char uidmap[kBufferSize], gidmap[kBufferSize];
- if (!userns_supported_) {
- SUCCEED();
- return;
- }
+ if (!userns_supported_)
+ GTEST_SKIP();
// We first create a child in a new userns so we have privs to run more tests.
// We can't combine the steps as the kernel disallows many resource sharing
@@ -1073,10 +1063,8 @@
constexpr uid_t kTargetUid = 1000; // Any non-zero value will do.
constexpr gid_t kTargetGid = 1000;
- if (!userns_supported_) {
- SUCCEED();
- return;
- }
+ if (!userns_supported_)
+ GTEST_SKIP();
struct minijail *j = minijail_new();
@@ -1125,10 +1113,8 @@
constexpr uid_t kTargetUid = 1000; // Any non-zero value will do.
constexpr gid_t kTargetGid = 1000;
- if (!userns_supported_) {
- SUCCEED();
- return;
- }
+ if (!userns_supported_)
+ GTEST_SKIP();
struct minijail *j = minijail_new();
@@ -1172,10 +1158,8 @@
constexpr uid_t kTargetUid = 1000; // Any non-zero value will do.
constexpr gid_t kTargetGid = 1000;
- if (!userns_supported_) {
- SUCCEED();
- return;
- }
+ if (!userns_supported_)
+ GTEST_SKIP();
struct minijail *j = minijail_new();