forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commita16b2b9
committed
Fix TAP test for remove_temp_files_after_crash
The test included incd91de0 had two simple flaws.Firstly, the number of rows was low and on some platforms (e.g. 32-bit)the sort did not require on-disk sort, so on those machines it was nottesting the automatic removal. The test was however failing, becausewithout any temporary files the base/pgsql_tmp directory was not evencreated. Fixed by increasing the rowcount to 5000, which should be highengough on any platform.Secondly, the test used a simple sleep to wait for the temporary file tobe created. This is obviously problematic, because on slow machines (orwith valgrind, CLOBBER_CACHE_ALWAYS etc.) it may take a while to createthe temporary file. But we also want the tests run reasonably fast.Fixed by instead relying on a UNIQUE constraint, blocking the query thatcreated the temporary file.Author: Euler TaveiraReviewed-by: Tomas VondraDiscussion:https://postgr.es/m/CAH503wDKdYzyq7U-QJqGn%3DGm6XmoK%2B6_6xTJ-Yn5WSvoHLY1Ww%40mail.gmail.com1 parent5b2266e commita16b2b9
1 file changed
+47
-13
lines changedOriginal file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
5 | 5 |
| |
6 | 6 |
| |
7 | 7 |
| |
8 |
| - | |
9 | 8 |
| |
10 | 9 |
| |
11 | 10 |
| |
| |||
33 | 32 |
| |
34 | 33 |
| |
35 | 34 |
| |
36 |
| - | |
37 |
| - | |
| 35 | + | |
38 | 36 |
| |
39 | 37 |
| |
40 | 38 |
| |
| |||
62 | 60 |
| |
63 | 61 |
| |
64 | 62 |
| |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
65 | 89 |
| |
66 | 90 |
| |
67 | 91 |
| |
68 | 92 |
| |
69 | 93 |
| |
70 | 94 |
| |
71 | 95 |
| |
72 |
| - | |
| 96 | + | |
73 | 97 |
| |
74 | 98 |
| |
75 |
| - | |
| 99 | + | |
76 | 100 |
| |
77 | 101 |
| |
78 | 102 |
| |
79 |
| - | |
80 |
| - | |
81 |
| - | |
82 | 103 |
| |
83 | 104 |
| |
84 | 105 |
| |
85 | 106 |
| |
86 | 107 |
| |
87 | 108 |
| |
| 109 | + | |
88 | 110 |
| |
89 | 111 |
| |
90 | 112 |
| |
| |||
118 | 140 |
| |
119 | 141 |
| |
120 | 142 |
| |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
121 | 157 |
| |
122 | 158 |
| |
123 | 159 |
| |
124 | 160 |
| |
125 | 161 |
| |
126 | 162 |
| |
127 | 163 |
| |
128 |
| - | |
| 164 | + | |
129 | 165 |
| |
130 | 166 |
| |
131 |
| - | |
| 167 | + | |
132 | 168 |
| |
133 | 169 |
| |
134 | 170 |
| |
135 |
| - | |
136 |
| - | |
137 |
| - | |
138 | 171 |
| |
139 | 172 |
| |
140 | 173 |
| |
141 | 174 |
| |
142 | 175 |
| |
143 | 176 |
| |
| 177 | + | |
144 | 178 |
| |
145 | 179 |
| |
146 | 180 |
| |
|
0 commit comments
Comments
(0)