Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 56064d5

Browse files
committed
Remove useless and rather expensive stanza in matview regression test.
This removes a test case added by commit b69ec7c, which was intended to exercise a corner case involving the rule used at that time that materialized views were unpopulated iff they had physical size zero. We got rid of that rule very shortly later, in commit 1d6c72a, but kept the test case. However, because the case now asks what VACUUM will do to a zero-sized physical file, it would be pretty surprising if the answer were ever anything but "nothing" ... and if things were indeed that broken, surely we'd find it out from other tests. Since the test involves a table that's fairly large by regression-test standards (100K rows), it's quite slow to run. Dropping it should save some buildfarm cycles, so let's do that. Discussion: https://postgr.es/m/32386.1493831320@sss.pgh.pa.us
1 parent c521d5a commit 56064d5

File tree

2 files changed

+0
-32
lines changed

2 files changed

+0
-32
lines changed

src/test/regress/expected/matview.out

-20
Original file line numberDiff line numberDiff line change
@@ -382,26 +382,6 @@ NOTICE: drop cascades to 3 other objects
382382
DETAIL: drop cascades to view mvtest_vt2
383383
drop cascades to materialized view mv_test2
384384
drop cascades to materialized view mv_test3
385-
-- test that vacuum does not make empty matview look unpopulated
386-
CREATE TABLE mvtest_huge (i int);
387-
INSERT INTO mvtest_huge VALUES (generate_series(1,100000));
388-
CREATE MATERIALIZED VIEW mvtest_hugeview AS SELECT * FROM mvtest_huge WHERE i % 2 = 0;
389-
CREATE INDEX mvtest_hugeviewidx ON mvtest_hugeview (i);
390-
DELETE FROM mvtest_huge;
391-
REFRESH MATERIALIZED VIEW mvtest_hugeview;
392-
SELECT * FROM mvtest_hugeview WHERE i < 10;
393-
i
394-
---
395-
(0 rows)
396-
397-
VACUUM ANALYZE mvtest_hugeview;
398-
SELECT * FROM mvtest_hugeview WHERE i < 10;
399-
i
400-
---
401-
(0 rows)
402-
403-
DROP TABLE mvtest_huge CASCADE;
404-
NOTICE: drop cascades to materialized view mvtest_hugeview
405385
-- test that duplicate values on unique index prevent refresh
406386
CREATE TABLE mvtest_foo(a, b) AS VALUES(1, 10);
407387
CREATE MATERIALIZED VIEW mvtest_mv AS SELECT * FROM mvtest_foo;

src/test/regress/sql/matview.sql

-12
Original file line numberDiff line numberDiff line change
@@ -122,18 +122,6 @@ SELECT relispopulated FROM pg_class WHERE oid = 'mv_test3'::regclass;
122122

123123
DROP VIEW mvtest_vt1 CASCADE;
124124

125-
-- test that vacuum does not make empty matview look unpopulated
126-
CREATE TABLE mvtest_huge (i int);
127-
INSERT INTO mvtest_huge VALUES (generate_series(1,100000));
128-
CREATE MATERIALIZED VIEW mvtest_hugeview AS SELECT * FROM mvtest_huge WHERE i % 2 = 0;
129-
CREATE INDEX mvtest_hugeviewidx ON mvtest_hugeview (i);
130-
DELETE FROM mvtest_huge;
131-
REFRESH MATERIALIZED VIEW mvtest_hugeview;
132-
SELECT * FROM mvtest_hugeview WHERE i < 10;
133-
VACUUM ANALYZE mvtest_hugeview;
134-
SELECT * FROM mvtest_hugeview WHERE i < 10;
135-
DROP TABLE mvtest_huge CASCADE;
136-
137125
-- test that duplicate values on unique index prevent refresh
138126
CREATE TABLE mvtest_foo(a, b) AS VALUES(1, 10);
139127
CREATE MATERIALIZED VIEW mvtest_mv AS SELECT * FROM mvtest_foo;

0 commit comments

Comments
 (0)