forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit3bfd401
committed
Improve regression test case to avoid depending on system catalog stats.
In commit95f4e59 I added a regression test case that examinedthe plan of a query on system catalogs. That isn't a terribly great ideabecause the catalogs tend to change from version to version, or evenwithin a version if someone makes an unrelated regression-test change thatpopulates the catalogs a bit differently. Usually I try to make plannertest cases rely on test tables that have not changed since Berkeley days,but I got sloppy in this case because the submitted crasher example queriedthe catalogs and I didn't spend enough time on rewriting it. But it was aproblem waiting to happen, as I was rudely reminded when I tried to portthat patch into Salesforce's Postgres variant :-(. So spend a little moreeffort and rewrite the query to not use any system catalogs. I verifiedthat this version still provokes the Assert if95f4e59's code fixis reverted.I also removed the EXPLAIN output from the test, as it turns out that theassertion occurs while considering a plan that isn't the one ultimatelyselected anyway; so there's no value in risking any cross-platformvariation in that printout.Back-patch to 9.2, like the previous patch.1 parent83fd922 commit3bfd401
2 files changed
+22
-64
lines changedLines changed: 13 additions & 43 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2186 | 2186 |
| |
2187 | 2187 |
| |
2188 | 2188 |
| |
2189 |
| - | |
| 2189 | + | |
2190 | 2190 |
| |
2191 |
| - | |
2192 |
| - | |
2193 |
| - | |
2194 |
| - | |
2195 |
| - | |
2196 |
| - | |
2197 |
| - | |
2198 |
| - | |
2199 |
| - | |
2200 |
| - | |
2201 |
| - | |
2202 |
| - | |
2203 |
| - | |
2204 |
| - | |
2205 |
| - | |
2206 |
| - | |
2207 |
| - | |
2208 |
| - | |
2209 |
| - | |
2210 |
| - | |
2211 |
| - | |
2212 |
| - | |
2213 |
| - | |
2214 |
| - | |
2215 |
| - | |
2216 |
| - | |
2217 |
| - | |
2218 |
| - | |
2219 |
| - | |
2220 |
| - | |
2221 |
| - | |
2222 |
| - | |
| 2191 | + | |
2223 | 2192 |
| |
2224 |
| - | |
2225 |
| - | |
2226 |
| - | |
2227 |
| - | |
2228 |
| - | |
2229 |
| - | |
2230 |
| - | |
2231 |
| - | |
2232 |
| - | |
2233 |
| - | |
| 2193 | + | |
| 2194 | + | |
| 2195 | + | |
| 2196 | + | |
| 2197 | + | |
| 2198 | + | |
| 2199 | + | |
| 2200 | + | |
| 2201 | + | |
| 2202 | + | |
| 2203 | + | |
2234 | 2204 |
| |
2235 | 2205 |
| |
2236 | 2206 |
| |
|
Lines changed: 9 additions & 21 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
367 | 367 |
| |
368 | 368 |
| |
369 | 369 |
| |
370 |
| - | |
| 370 | + | |
371 | 371 |
| |
372 |
| - | |
373 |
| - | |
374 |
| - | |
375 |
| - | |
376 |
| - | |
377 |
| - | |
378 |
| - | |
379 |
| - | |
380 |
| - | |
381 |
| - | |
382 |
| - | |
383 |
| - | |
384 |
| - | |
| 372 | + | |
385 | 373 |
| |
386 |
| - | |
387 |
| - | |
388 |
| - | |
389 |
| - | |
390 |
| - | |
391 |
| - | |
392 |
| - | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
| 380 | + | |
393 | 381 |
| |
394 | 382 |
| |
395 | 383 |
| |
|
0 commit comments
Comments
(0)