|
52 | 52 |
|
53 | 53 | #include "../kselftest_harness.h"
|
54 | 54 |
|
| 55 | +/* Attempt to de-conflict with the selftests tree. */ |
| 56 | +#ifndef SKIP |
| 57 | +#define SKIP(s, ...) XFAIL(s, ##__VA_ARGS__) |
| 58 | +#endif |
| 59 | + |
55 | 60 | #ifndef PR_SET_PTRACER
|
56 | 61 | # define PR_SET_PTRACER 0x59616d61
|
57 | 62 | #endif
|
@@ -3068,7 +3073,7 @@ TEST(get_metadata)
|
3068 | 3073 |
|
3069 | 3074 | /* Only real root can get metadata. */
|
3070 | 3075 | if (geteuid()) {
|
3071 |
| - XFAIL(return, "get_metadata requires real root"); |
| 3076 | + SKIP(return, "get_metadata requires real root"); |
3072 | 3077 | return;
|
3073 | 3078 | }
|
3074 | 3079 |
|
@@ -3111,7 +3116,7 @@ TEST(get_metadata)
|
3111 | 3116 | ret = ptrace(PTRACE_SECCOMP_GET_METADATA, pid, sizeof(md), &md);
|
3112 | 3117 | EXPECT_EQ(sizeof(md), ret) {
|
3113 | 3118 | if (errno == EINVAL)
|
3114 |
| - XFAIL(goto skip, "Kernel does not support PTRACE_SECCOMP_GET_METADATA (missing CONFIG_CHECKPOINT_RESTORE?)"); |
| 3119 | + SKIP(goto skip, "Kernel does not support PTRACE_SECCOMP_GET_METADATA (missing CONFIG_CHECKPOINT_RESTORE?)"); |
3115 | 3120 | }
|
3116 | 3121 |
|
3117 | 3122 | EXPECT_EQ(md.flags, SECCOMP_FILTER_FLAG_LOG);
|
@@ -3672,15 +3677,15 @@ TEST(user_notification_continue)
|
3672 | 3677 | resp.val = 0;
|
3673 | 3678 | EXPECT_EQ(ioctl(listener, SECCOMP_IOCTL_NOTIF_SEND, &resp), 0) {
|
3674 | 3679 | if (errno == EINVAL)
|
3675 |
| - XFAIL(goto skip, "Kernel does not support SECCOMP_USER_NOTIF_FLAG_CONTINUE"); |
| 3680 | + SKIP(goto skip, "Kernel does not support SECCOMP_USER_NOTIF_FLAG_CONTINUE"); |
3676 | 3681 | }
|
3677 | 3682 |
|
3678 | 3683 | skip:
|
3679 | 3684 | EXPECT_EQ(waitpid(pid, &status, 0), pid);
|
3680 | 3685 | EXPECT_EQ(true, WIFEXITED(status));
|
3681 | 3686 | EXPECT_EQ(0, WEXITSTATUS(status)) {
|
3682 | 3687 | if (WEXITSTATUS(status) == 2) {
|
3683 |
| - XFAIL(return, "Kernel does not support kcmp() syscall"); |
| 3688 | + SKIP(return, "Kernel does not support kcmp() syscall"); |
3684 | 3689 | return;
|
3685 | 3690 | }
|
3686 | 3691 | }
|
|
0 commit comments