Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dXADA-0006aB-K9 for pgsql-hackers@arkaria.postgresql.org; Mon, 17 Jul 2017 17:53:36 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1dXAD9-0004u3-8e for pgsql-hackers@arkaria.postgresql.org; Mon, 17 Jul 2017 17:53:35 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dXAD7-0004rb-EZ for pgsql-hackers@postgresql.org; Mon, 17 Jul 2017 17:53:33 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dXAD0-0005hz-2h for pgsql-hackers@postgresql.org; Mon, 17 Jul 2017 17:53:33 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id v6HHrOCc028993; Mon, 17 Jul 2017 13:53:24 -0400 From: Tom Lane To: Stephen Frost cc: pgsql-hackers@postgresql.org Subject: Re: Why have we got both largeobject and large_object test files? In-reply-to: <20170717165948.GA1769@tamriel.snowman.net> References: <18665.1500306372@sss.pgh.pa.us> <20170717165948.GA1769@tamriel.snowman.net> Comments: In-reply-to Stephen Frost message dated "Mon, 17 Jul 2017 12:59:48 -0400" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <28991.1500314004.1@sss.pgh.pa.us> Date: Mon, 17 Jul 2017 13:53:24 -0400 Message-ID: <28992.1500314004@sss.pgh.pa.us> List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org Stephen Frost writes: > * Tom Lane (tgl@sss.pgh.pa.us) wrote: >> I happened to notice that the regression tests contain both >> largeobject.sql and large_object.sql. This seems at best confusing and at >> worst a source of mistakes. The second file was added in March by commit >> ff992c074, has never been touched by any other commit, and is only 8 lines >> long. Was there a really good reason not to incorporate that test into >> largeobject.sql? > Just to be clear that we're talking about the same thing- there is no > 'largeobject.sql' in a clean source tree. There is a 'largeobject.source' > in src/test/regress/input which is converted to largeobject.sql. Right, sorry for the imprecision. > As for the general question of if the two could be merged, I can't think > of any reason off-hand why that wouldn't work, nor do I have any > particular recollection as to why I created a new file instead of using > the existing. My shell history tells me that I found largeobject.source > while crafting the test case but not why I didn't use it. You've got shell history back to March? Wow. > The main thing is that the large_object.sql was specifically added to > test pg_upgrade/pg_dump, so the created object needs to be kept around > in the regression database with the comment after the tests run for that > to happen. Right. I was thinking of just appending large_object.sql to the end of the other file. It's possible that there's some issue involving race conditions against some concurrent test, but I'll look around. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers