postgresql/src/test
Stephen Frost 814b9e9b8e Fix RLS with COPY (col1, col2) FROM tab
Attempting to COPY a subset of columns from a table with RLS enabled
would fail due to an invalid query being constructed (using a single
ColumnRef with the list of fields to exact in 'fields', but that's for
the different levels of an indirection for a single column, not for
specifying multiple columns).

Correct by building a ColumnRef and then RestTarget for each column
being requested and then adding those to the targetList for the select
query.  Include regression tests to hopefully catch if this is broken
again in the future.

Patch-By: Adam Brightwell
Reviewed-By: Michael Paquier
2016-10-03 16:22:57 -04:00
..
examples Include <sys/select.h> where needed 2016-09-27 01:05:21 -03:00
isolation Be sure to rewind the tuplestore read pointer in non-leader CTEScan nodes. 2016-09-22 11:35:03 -04:00
locale Fix omission of -X (--no-psqlrc) in some psql invocations. 2015-12-28 11:46:43 -05:00
mb Revert "Fix broken multibyte regression tests." 2016-01-26 08:29:15 +09:00
modules worker_spi: Call pgstat_report_stat. 2016-09-28 12:42:48 -04:00
perl Set log_line_prefix and application name in test drivers 2016-09-30 21:32:33 -04:00
recovery Dirty replication slots when using sql interface 2016-09-05 09:44:38 +01:00
regress Fix RLS with COPY (col1, col2) FROM tab 2016-10-03 16:22:57 -04:00
ssl Support OpenSSL 1.1.0. 2016-09-15 14:42:29 +03:00
thread Update copyright for 2016 2016-01-02 13:33:40 -05:00
Makefile Install TAP test infrastructure so it's available for extension testing. 2016-09-23 15:50:00 -04:00
README Minor tweaks for new src/test/recovery 2016-02-29 18:16:59 -03:00

PostgreSQL tests
================

This directory contains a variety of test infrastructure as well as some of the
tests in PostgreSQL. Not all tests are here -- in particular, there are more in
individual contrib/ modules and in src/bin.

Not all these tests get run by "make check". Check src/test/Makefile to see
which tests get run automatically.

examples/
  Demonstration programs for libpq that double as regression tests via
  "make check"

isolation/
  Tests for concurrent behavior at the SQL level

locale/
  Sanity checks for locale data, encodings, etc

mb/
  Tests for multibyte encoding (UTF-8) support

modules/
  Extensions used only or mainly for test purposes, generally not suitable
  for installing in production databases

perl/
  Infrastructure for Perl-based TAP tests

recovery/
  Test suite for recovery and replication

regress/
  PostgreSQL's main regression test suite, pg_regress

ssl/
  Tests to exercise and verify SSL certificate handling

thread/
  A thread-safety-testing utility used by configure