Re: Convert sepgsql tests to TAP - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Convert sepgsql tests to TAP
Date
Msg-id 554924.1737757767@sss.pgh.pa.us
Whole thread Raw
In response to Re: Convert sepgsql tests to TAP  (Andrew Dunstan <andrew@dunslane.net>)
Responses Re: Convert sepgsql tests to TAP
Re: Convert sepgsql tests to TAP
List pgsql-hackers
Andrew Dunstan <andrew@dunslane.net> writes:
> On 2025-01-24 Fr 4:07 PM, Tom Lane wrote:
>> Looking at the buildfarm client script, it looks to me like it
>> will unconditionally try to run TAP tests in every contrib directory
>> that has a "t" subdirectory.  Up to now, none of those needed to
>> be conditional ... but now we need some more awareness.

> The new TAP test has:

> +if (!$ENV{PG_TEST_EXTRA} || $ENV{PG_TEST_EXTRA} !~ /\bsepgsql\b/)
> +{
> +   plan skip_all =>
> +     'Potentially unsafe test sepgsql not enabled in PG_TEST_EXTRA';
> +}

Yeah, but to get to that point you have to get past "make install",
which requires compiling the code, which will absolutely not work
on these platforms.  alligator and lapwing are not reporting the
relevant log file, but what we do see is an install failure that
could well be down to a compile failure.

> But why is it doing that? On my Ubuntu 22.04 dev instance, this test shows this as expected:

I don't understand how you're compiling on Ubuntu ... does it
have selinux installed?  On a Mac for instance,

$ cd pgsql/contrib/sepgsql/
$ make install
...
In file included from database.c:21:
./sepgsql.h:17:10: fatal error: 'selinux/selinux.h' file not found
   17 | #include <selinux/selinux.h>
      |          ^~~~~~~~~~~~~~~~~~~
1 error generated.


> As of now I'm confused ...

Me too.  The way it looks from here, the farm should be all red,
but it isn't.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Tomas Vondra
Date:
Subject: Re: Enhancing Memory Context Statistics Reporting
Next
From: Tom Lane
Date:
Subject: Re: Convert sepgsql tests to TAP