Hello!It would be more natural just to declare this test (of a feature which has not yet been implemented) as "X-FAIL"; I mean: which is expected to fail. It will always be run, and in future, if something changes, we'll notice the change in the test results and act accordingly.
Does the testing system (dejagnu?) has a way to say that a test is expected not to pass, but to fail (and not count it as a real failure)?
(A switch like a define is better suited to reflect the features of the environment, external to our project; as an advice for the other patch: perhaps, whether we have the debuginfo for glibc available could be reflected by a "switch".)
-- Best regards, Ivan
>From eabab14cba3a0071f8e4b743cc0b2ee698865cae Mon Sep 17 00:00:00 2001 From: Grigory Ustinov <[email protected]> Date: Fri, 17 Nov 2017 19:05:49 +0300 Subject: [PATCH 1/5] Fix FAIL in attach process tests When made tests, they dropped with following error: Cannot attach to pid $PID: Operation not permitted --- testsuite/ltrace.minor/attach-process-dlopen.exp | 2 ++ testsuite/ltrace.minor/attach-process.exp | 2 ++ 2 files changed, 4 insertions(+) diff --git a/testsuite/ltrace.minor/attach-process-dlopen.exp b/testsuite/ltrace.minor/attach-process-dlopen.exp index ac61347..afb8b75 100644 --- a/testsuite/ltrace.minor/attach-process-dlopen.exp +++ b/testsuite/ltrace.minor/attach-process-dlopen.exp @@ -29,7 +29,9 @@ spawn [ltraceCompile exe -ldl [ltraceSource c { #include <assert.h> #include <stdio.h> #include <string.h> + #include <sys/prctl.h> int main(int argc, char **argv) { + (void) prctl(PR_SET_PTRACER, PR_SET_PTRACER_ANY); assert(argc == 2); #define FN "libll.so" char buf[strlen(argv[1]) + 1 + sizeof FN]; diff --git a/testsuite/ltrace.minor/attach-process.exp b/testsuite/ltrace.minor/attach-process.exp index 1249bd3..e6ccdf5 100644 --- a/testsuite/ltrace.minor/attach-process.exp +++ b/testsuite/ltrace.minor/attach-process.exp @@ -18,7 +18,9 @@ set bin [ltraceCompile {} [ltraceSource c { #include <unistd.h> + #include <sys/prctl.h> int main(void) { + (void) prctl(PR_SET_PTRACER, PR_SET_PTRACER_ANY); sleep(5); sleep(1); return 0; -- 2.10.4
_______________________________________________ Ltrace-devel mailing list [email protected] http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/ltrace-devel
