summaryrefslogtreecommitdiffhomepage
path: root/test/syscalls/linux/ptrace.cc
diff options
context:
space:
mode:
authorAdin Scannell <ascannell@google.com>2020-01-27 22:27:57 -0800
committergVisor bot <gvisor-bot@google.com>2020-01-27 22:28:43 -0800
commit5d569408ef94c753b7aae9392b5e4ebf7e5ea50d (patch)
treeb34260f2e94e62b4ee3f4bff45644c39fdf0fecd /test/syscalls/linux/ptrace.cc
parent2a2da5be31ea3c32e66f0c0ff61ef189848f5258 (diff)
Create platform_util for tests.
PiperOrigin-RevId: 291869423
Diffstat (limited to 'test/syscalls/linux/ptrace.cc')
-rw-r--r--test/syscalls/linux/ptrace.cc10
1 files changed, 3 insertions, 7 deletions
diff --git a/test/syscalls/linux/ptrace.cc b/test/syscalls/linux/ptrace.cc
index ef67b747b..4dd5cf27b 100644
--- a/test/syscalls/linux/ptrace.cc
+++ b/test/syscalls/linux/ptrace.cc
@@ -32,6 +32,7 @@
#include "absl/time/time.h"
#include "test/util/logging.h"
#include "test/util/multiprocess_util.h"
+#include "test/util/platform_util.h"
#include "test/util/signal_util.h"
#include "test/util/test_util.h"
#include "test/util/thread_util.h"
@@ -824,13 +825,8 @@ TEST(PtraceTest,
// These tests requires knowledge of architecture-specific syscall convention.
#ifdef __x86_64__
TEST(PtraceTest, Int3) {
- switch (GvisorPlatform()) {
- case Platform::kKVM:
- // TODO(b/124248694): int3 isn't handled properly.
- return;
- default:
- break;
- }
+ SKIP_IF(PlatformSupportInt3() == PlatformSupport::NotSupported);
+
pid_t const child_pid = fork();
if (child_pid == 0) {
// In child process.