pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Testing an extension against multiple versions of Postgresql
4+ messages / 3 participants
[nested] [flat]

* Testing an extension against multiple versions of Postgresql
@ 2019-07-13 01:55 Rhys A.D. Stewart <rhys.stewart@gmail.com>
  2019-07-13 06:03 ` Re: Testing an extension against multiple versions of Postgresql Ian Barwick <ian.barwick@2ndquadrant.com>
  0 siblings, 1 reply; 4+ messages in thread

From: Rhys A.D. Stewart @ 2019-07-13 01:55 UTC (permalink / raw)
  To: pgsql-general

Greetings All,

I have both postgresql versions 10 and 11 installed on my box. I'm working
on an extension and just realized that 'make install' installs the
extension to the 11 server, but 'make installcheck' runs against the 10
server (I had previously installed the extension there).

Running psql without specifying a host or port connects me to the 10
server, so I suspect that both make installcheck and psql are doing similar
things with respect to connecting to a default server.

So the questions are:
Can I have make install & make installcheck run against multiple versions
at the same time or how do I tell the installcheck to run against the 11
server.

Thanks.

Rhys
Peace & Love | Live Long & Prosper

^ permalink  raw  reply  [nested|flat] 4+ messages in thread

* Re: Testing an extension against multiple versions of Postgresql
  2019-07-13 01:55 Testing an extension against multiple versions of Postgresql Rhys A.D. Stewart <rhys.stewart@gmail.com>
@ 2019-07-13 06:03 ` Ian Barwick <ian.barwick@2ndquadrant.com>
  2019-07-13 08:15   ` Re: Testing an extension against multiple versions of Postgresql Luca Ferrari <fluca1978@gmail.com>
  0 siblings, 1 reply; 4+ messages in thread

From: Ian Barwick @ 2019-07-13 06:03 UTC (permalink / raw)
  To: Rhys A.D. Stewart <rhys.stewart@gmail.com>; pgsql-general

On 7/13/19 10:55 AM, Rhys A.D. Stewart wrote:
> Greetings All,
> 
> I have both postgresql versions 10 and 11 installed on my box. I'm working on an extension and just realized that 'make install' installs the extension to the 11 server, but 'make installcheck' runs against the 10 server (I had previously installed the extension there).
> 
> Running psql without specifying a host or port connects me to the 10 server, so I suspect that both make installcheck and psql are doing similar things with respect to connecting to a default server.
> 
> So the questions are:
> Can I have make install & make installcheck run against multiple versions at the same time or how do I tell the installcheck to run against the 11 server.

Try setting relevant environment variables [*] for the target version before running "make installcheck".

[*] https://www.postgresql.org/docs/current//libpq-envars.html


Regards

Ian Barwick

-- 
  Ian Barwick                   https://www.2ndQuadrant.com/
  PostgreSQL Development, 24x7 Support, Training & Services





^ permalink  raw  reply  [nested|flat] 4+ messages in thread

* Re: Testing an extension against multiple versions of Postgresql
  2019-07-13 01:55 Testing an extension against multiple versions of Postgresql Rhys A.D. Stewart <rhys.stewart@gmail.com>
  2019-07-13 06:03 ` Re: Testing an extension against multiple versions of Postgresql Ian Barwick <ian.barwick@2ndquadrant.com>
@ 2019-07-13 08:15   ` Luca Ferrari <fluca1978@gmail.com>
  2019-07-13 14:44     ` Re: Testing an extension against multiple versions of Postgresql Rhys A.D. Stewart <rhys.stewart@gmail.com>
  0 siblings, 1 reply; 4+ messages in thread

From: Luca Ferrari @ 2019-07-13 08:15 UTC (permalink / raw)
  To: Ian Barwick <ian.barwick@2ndquadrant.com>; +Cc: Rhys A.D. Stewart <rhys.stewart@gmail.com>; pgsql-general

On Sat, Jul 13, 2019 at 8:03 AM Ian Barwick <ian.barwick@2ndquadrant.com> wrote:
> > So the questions are:
> > Can I have make install & make installcheck run against multiple versions at the same time or how do I tell the installcheck to run against the 11 server.
>
> Try setting relevant environment variables [*] for the target version before running "make installcheck".
>
> [*] https://www.postgresql.org/docs/current//libpq-envars.html
>

Aside that, a possible easy way to test something against different
PostgreSQL instance is to use something like pgenv
<https://github.com/theory/pgenv;, that is for instance used to test
sqitch.

Luca





^ permalink  raw  reply  [nested|flat] 4+ messages in thread

* Re: Testing an extension against multiple versions of Postgresql
  2019-07-13 01:55 Testing an extension against multiple versions of Postgresql Rhys A.D. Stewart <rhys.stewart@gmail.com>
  2019-07-13 06:03 ` Re: Testing an extension against multiple versions of Postgresql Ian Barwick <ian.barwick@2ndquadrant.com>
  2019-07-13 08:15   ` Re: Testing an extension against multiple versions of Postgresql Luca Ferrari <fluca1978@gmail.com>
@ 2019-07-13 14:44     ` Rhys A.D. Stewart <rhys.stewart@gmail.com>
  0 siblings, 0 replies; 4+ messages in thread

From: Rhys A.D. Stewart @ 2019-07-13 14:44 UTC (permalink / raw)
  To: Luca Ferrari <fluca1978@gmail.com>; +Cc: Ian Barwick <ian.barwick@2ndquadrant.com>; pgsql-general

Thanks!!

Rhys
Peace & Love|Live Long & Prosper


On Sat, Jul 13, 2019 at 3:15 AM Luca Ferrari <fluca1978@gmail.com> wrote:

> On Sat, Jul 13, 2019 at 8:03 AM Ian Barwick <ian.barwick@2ndquadrant.com>
> wrote:
> > > So the questions are:
> > > Can I have make install & make installcheck run against multiple
> versions at the same time or how do I tell the installcheck to run against
> the 11 server.
> >
> > Try setting relevant environment variables [*] for the target version
> before running "make installcheck".
> >
> > [*] https://www.postgresql.org/docs/current//libpq-envars.html
> >
>
> Aside that, a possible easy way to test something against different
> PostgreSQL instance is to use something like pgenv
> <https://github.com/theory/pgenv;, that is for instance used to test
> sqitch.
>
> Luca
>

^ permalink  raw  reply  [nested|flat] 4+ messages in thread


end of thread, other threads:[~2019-07-13 14:44 UTC | newest]

Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2019-07-13 01:55 Testing an extension against multiple versions of Postgresql Rhys A.D. Stewart <rhys.stewart@gmail.com>
2019-07-13 06:03 ` Ian Barwick <ian.barwick@2ndquadrant.com>
2019-07-13 08:15   ` Luca Ferrari <fluca1978@gmail.com>
2019-07-13 14:44     ` Rhys A.D. Stewart <rhys.stewart@gmail.com>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox