From: Babanpreet Singh <bbnpreetsingh@gmail.com>
To: openembedded-devel@lists.openembedded.org
Cc: Khem Raj <raj.khem@gmail.com>,
Babanpreet Singh <bbnpreetsingh@gmail.com>
Subject: [meta-oe][PATCH 1/3] ptest-pgxs.bbclass: install expected output from --expecteddir
Date: Fri, 4 Dec 2026 01:58:21 +0000 [thread overview]
Message-ID: <20261204015823.7-2-bbnpreetsingh@gmail.com> (raw)
In-Reply-To: <20261204015823.7-1-bbnpreetsingh@gmail.com>
pg_regress takes expected output from --expecteddir, by default the
directory it runs in, and only then from --inputdir. An extension that
keeps its expected output there, apart from the SQL in --inputdir, got
no expected files in its ptest.
Signed-off-by: Babanpreet Singh <bbnpreetsingh@gmail.com>
---
meta-oe/classes/ptest-pgxs.bbclass | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/meta-oe/classes/ptest-pgxs.bbclass b/meta-oe/classes/ptest-pgxs.bbclass
index fd2832085a..e4dd4c6c07 100644
--- a/meta-oe/classes/ptest-pgxs.bbclass
+++ b/meta-oe/classes/ptest-pgxs.bbclass
@@ -31,6 +31,7 @@ EOF
conf=""
opts=""
inputdir=.
+ expecteddir=.
schedules=""
# REGRESS_OPTS is split on whitespace, so an option whose value
# contains spaces or quotes is not supported
@@ -39,6 +40,7 @@ EOF
--temp-config=*) conf=$(basename "${o#--temp-config=}") ;;
--temp-instance=*|--dbname=*) ;;
--inputdir=*) inputdir="${o#--inputdir=}"; opts="$opts $o" ;;
+ --expecteddir=*) expecteddir="${o#--expecteddir=}"; opts="$opts $o" ;;
--schedule=*)
schedules="$schedules ${o#--schedule=}"
opts="$opts --schedule=$(basename "${o#--schedule=}")"
@@ -53,6 +55,10 @@ EOF
cp -r ${S}/${PTEST_PGXS_DIR}/$inputdir/$d ${D}${PTEST_PATH}/tests/$inputdir/
fi
done
+ if [ "$expecteddir" != "$inputdir" ] && [ -d ${S}/${PTEST_PGXS_DIR}/$expecteddir/expected ]; then
+ install -d ${D}${PTEST_PATH}/tests/$expecteddir
+ cp -r ${S}/${PTEST_PGXS_DIR}/$expecteddir/expected ${D}${PTEST_PATH}/tests/$expecteddir/
+ fi
for s in $schedules; do
install -m 0644 ${S}/${PTEST_PGXS_DIR}/$s ${D}${PTEST_PATH}/tests/
done
--
2.43.0
next prev parent reply other threads:[~2026-12-04 1:58 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-12-04 1:58 [meta-oe][PATCH 0/3] ptest-pgxs.bbclass: three fixes from porting more extensions Babanpreet Singh
2026-12-04 1:58 ` Babanpreet Singh [this message]
2026-12-04 1:58 ` [meta-oe][PATCH 2/3] ptest-pgxs.bbclass: read EXTRA_REGRESS_OPTS too Babanpreet Singh
2026-12-04 1:58 ` [meta-oe][PATCH 3/3] ptest-pgxs.bbclass: create the test database as UTF8 Babanpreet Singh
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261204015823.7-2-bbnpreetsingh@gmail.com \
--to=bbnpreetsingh@gmail.com \
--cc=openembedded-devel@lists.openembedded.org \
--cc=raj.khem@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.