Skip to content

Commit afaccbb

Browse files
committed
Rename object in test to avoid conflict
In 01e658f, the hash_func test creates a type t1, but apparently a test running in parallel might also use that name, depending on timing. Rename the type to avoid the issue.
1 parent 01e658f commit afaccbb

File tree

2 files changed

+14
-14
lines changed

2 files changed

+14
-14
lines changed

src/test/regress/expected/hash_func.out

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -305,24 +305,24 @@ WHERE hash_range(v)::bit(32) != hash_range_extended(v, 0)::bit(32)
305305
-------+----------+-----------+-----------
306306
(0 rows)
307307

308-
CREATE TYPE t1 AS (a int, b text);
308+
CREATE TYPE hash_test_t1 AS (a int, b text);
309309
SELECT v as value, hash_record(v)::bit(32) as standard,
310310
hash_record_extended(v, 0)::bit(32) as extended0,
311311
hash_record_extended(v, 1)::bit(32) as extended1
312-
FROM (VALUES (row(1, 'aaa')::t1, row(2, 'bbb'), row(-1, 'ccc'))) x(v)
312+
FROM (VALUES (row(1, 'aaa')::hash_test_t1, row(2, 'bbb'), row(-1, 'ccc'))) x(v)
313313
WHERE hash_record(v)::bit(32) != hash_record_extended(v, 0)::bit(32)
314314
OR hash_record(v)::bit(32) = hash_record_extended(v, 1)::bit(32);
315315
value | standard | extended0 | extended1
316316
-------+----------+-----------+-----------
317317
(0 rows)
318318

319-
DROP TYPE t1;
319+
DROP TYPE hash_test_t1;
320320
-- record hashing with non-hashable field type
321-
CREATE TYPE t2 AS (a money, b text);
321+
CREATE TYPE hash_test_t2 AS (a money, b text);
322322
SELECT v as value, hash_record(v)::bit(32) as standard
323-
FROM (VALUES (row(1, 'aaa')::t2)) x(v);
323+
FROM (VALUES (row(1, 'aaa')::hash_test_t2)) x(v);
324324
ERROR: could not identify a hash function for type money
325325
SELECT v as value, hash_record_extended(v, 0)::bit(32) as extended0
326-
FROM (VALUES (row(1, 'aaa')::t2)) x(v);
326+
FROM (VALUES (row(1, 'aaa')::hash_test_t2)) x(v);
327327
ERROR: could not identify an extended hash function for type money
328-
DROP TYPE t2;
328+
DROP TYPE hash_test_t2;

src/test/regress/sql/hash_func.sql

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -227,19 +227,19 @@ FROM (VALUES (int4range(10, 20)), (int4range(23, 43)),
227227
WHERE hash_range(v)::bit(32) != hash_range_extended(v, 0)::bit(32)
228228
OR hash_range(v)::bit(32) = hash_range_extended(v, 1)::bit(32);
229229

230-
CREATE TYPE t1 AS (a int, b text);
230+
CREATE TYPE hash_test_t1 AS (a int, b text);
231231
SELECT v as value, hash_record(v)::bit(32) as standard,
232232
hash_record_extended(v, 0)::bit(32) as extended0,
233233
hash_record_extended(v, 1)::bit(32) as extended1
234-
FROM (VALUES (row(1, 'aaa')::t1, row(2, 'bbb'), row(-1, 'ccc'))) x(v)
234+
FROM (VALUES (row(1, 'aaa')::hash_test_t1, row(2, 'bbb'), row(-1, 'ccc'))) x(v)
235235
WHERE hash_record(v)::bit(32) != hash_record_extended(v, 0)::bit(32)
236236
OR hash_record(v)::bit(32) = hash_record_extended(v, 1)::bit(32);
237-
DROP TYPE t1;
237+
DROP TYPE hash_test_t1;
238238

239239
-- record hashing with non-hashable field type
240-
CREATE TYPE t2 AS (a money, b text);
240+
CREATE TYPE hash_test_t2 AS (a money, b text);
241241
SELECT v as value, hash_record(v)::bit(32) as standard
242-
FROM (VALUES (row(1, 'aaa')::t2)) x(v);
242+
FROM (VALUES (row(1, 'aaa')::hash_test_t2)) x(v);
243243
SELECT v as value, hash_record_extended(v, 0)::bit(32) as extended0
244-
FROM (VALUES (row(1, 'aaa')::t2)) x(v);
245-
DROP TYPE t2;
244+
FROM (VALUES (row(1, 'aaa')::hash_test_t2)) x(v);
245+
DROP TYPE hash_test_t2;

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy