\set ECHO none 1..334 ok 1 - Type semver should exist ok 2 - semvers should be NULLable ok 3 - "1.2.2" is a valid semver ok 4 - "0.2.2" is a valid semver ok 5 - "0.0.0" is a valid semver ok 6 - "0.1.999" is a valid semver ok 7 - "9999.9999999.823823" is a valid semver ok 8 - "1.0.0-beta1" is a valid semver ok 9 - "1.0.0-beta2" is a valid semver ok 10 - "1.0.0" is a valid semver ok 11 - "1.0.0-1" is a valid semver ok 12 - "1.0.0-alpha+d34dm34t" is a valid semver ok 13 - "1.0.0+d34dm34t" is a valid semver ok 14 - "20110204.0.0" is a valid semver ok 15 - "1.0.0-alpha.0a" is a valid semver ok 16 - "1.0.0+010" is a valid semver ok 17 - "1.0.0+alpha.010" is a valid semver ok 18 - "1.0.0-0AEF" is a valid semver ok 19 - "1.2" is not a valid semver ok 20 - "1.2.02" is not a valid semver ok 21 - "1.2.2-" is not a valid semver ok 22 - "1.2.3b#5" is not a valid semver ok 23 - "03.3.3" is not a valid semver ok 24 - "v1.2.2" is not a valid semver ok 25 - "1.3b" is not a valid semver ok 26 - "1.4b.0" is not a valid semver ok 27 - "1v" is not a valid semver ok 28 - "1v.2.2v" is not a valid semver ok 29 - "1.2.4b.5" is not a valid semver ok 30 - "1.0.0-alpha.010" is not a valid semver ok 31 - "1.0.0-02799" is not a valid semver ok 32 - "1.1.2+.123" is not a valid semver ok 33 - "1.1.2-.123" is not a valid semver ok 34 - "1.2.3-ñø" is not a valid semver ok 35 - "1.2.3+ñø1" is not a valid semver ok 36 - semver(1.2.2, 1.2.2) should = 0 ok 37 - v1.2.2 should = v1.2.2 ok 38 - v1.2.2 should be <= v1.2.2 ok 39 - v1.2.2 should be >= v1.2.2 ok 40 - semver(1.2.23, 1.2.23) should = 0 ok 41 - v1.2.23 should = v1.2.23 ok 42 - v1.2.23 should be <= v1.2.23 ok 43 - v1.2.23 should be >= v1.2.23 ok 44 - semver(0.0.0, 0.0.0) should = 0 ok 45 - v0.0.0 should = v0.0.0 ok 46 - v0.0.0 should be <= v0.0.0 ok 47 - v0.0.0 should be >= v0.0.0 ok 48 - semver(999.888.7777, 999.888.7777) should = 0 ok 49 - v999.888.7777 should = v999.888.7777 ok 50 - v999.888.7777 should be <= v999.888.7777 ok 51 - v999.888.7777 should be >= v999.888.7777 ok 52 - semver(0.1.2-beta3, 0.1.2-beta3) should = 0 ok 53 - v0.1.2-beta3 should = v0.1.2-beta3 ok 54 - v0.1.2-beta3 should be <= v0.1.2-beta3 ok 55 - v0.1.2-beta3 should be >= v0.1.2-beta3 ok 56 - semver(1.2.2, 1.2.3) should <> 0 ok 57 - v1.2.2 should not equal v1.2.3 ok 58 - semver(0.0.1, 1.0.0) should <> 0 ok 59 - v0.0.1 should not equal v1.0.0 ok 60 - semver(1.0.1, 1.1.0) should <> 0 ok 61 - v1.0.1 should not equal v1.1.0 ok 62 - semver(1.1.1, 1.1.0) should <> 0 ok 63 - v1.1.1 should not equal v1.1.0 ok 64 - semver(1.2.3-b, 1.2.3) should <> 0 ok 65 - v1.2.3-b should not equal v1.2.3 ok 66 - semver(1.2.3, 1.2.3-b) should <> 0 ok 67 - v1.2.3 should not equal v1.2.3-b ok 68 - semver(1.2.3-a, 1.2.3-b) should <> 0 ok 69 - v1.2.3-a should not equal v1.2.3-b ok 70 - semver(1.2.3-aaaaaaa1, 1.2.3-aaaaaaa2) should <> 0 ok 71 - v1.2.3-aaaaaaa1 should not equal v1.2.3-aaaaaaa2 ok 72 - semver(1.2.3-1.2.3, 1.2.3-1.2.3.4) should <> 0 ok 73 - v1.2.3-1.2.3 should not equal v1.2.3-1.2.3.4 ok 74 - semver(2.2.2, 1.1.1) should > 0 ok 75 - semver(1.1.1, 2.2.2) should < 0 ok 76 - v2.2.2 should be > v1.1.1 ok 77 - v2.2.2 should be >= v1.1.1 ok 78 - v1.1.1 should be < v2.2.2 ok 79 - v1.1.1 should be <= v2.2.2 ok 80 - semver(2.2.2, 2.1.1) should > 0 ok 81 - semver(2.1.1, 2.2.2) should < 0 ok 82 - v2.2.2 should be > v2.1.1 ok 83 - v2.2.2 should be >= v2.1.1 ok 84 - v2.1.1 should be < v2.2.2 ok 85 - v2.1.1 should be <= v2.2.2 ok 86 - semver(2.2.2, 2.2.1) should > 0 ok 87 - semver(2.2.1, 2.2.2) should < 0 ok 88 - v2.2.2 should be > v2.2.1 ok 89 - v2.2.2 should be >= v2.2.1 ok 90 - v2.2.1 should be < v2.2.2 ok 91 - v2.2.1 should be <= v2.2.2 ok 92 - semver(2.2.2-b, 2.2.1) should > 0 ok 93 - semver(2.2.1, 2.2.2-b) should < 0 ok 94 - v2.2.2-b should be > v2.2.1 ok 95 - v2.2.2-b should be >= v2.2.1 ok 96 - v2.2.1 should be < v2.2.2-b ok 97 - v2.2.1 should be <= v2.2.2-b ok 98 - semver(2.2.2, 2.2.2-b) should > 0 ok 99 - semver(2.2.2-b, 2.2.2) should < 0 ok 100 - v2.2.2 should be > v2.2.2-b ok 101 - v2.2.2 should be >= v2.2.2-b ok 102 - v2.2.2-b should be < v2.2.2 ok 103 - v2.2.2-b should be <= v2.2.2 ok 104 - semver(2.2.2-c, 2.2.2-b) should > 0 ok 105 - semver(2.2.2-b, 2.2.2-c) should < 0 ok 106 - v2.2.2-c should be > v2.2.2-b ok 107 - v2.2.2-c should be >= v2.2.2-b ok 108 - v2.2.2-b should be < v2.2.2-c ok 109 - v2.2.2-b should be <= v2.2.2-c ok 110 - semver(2.2.2-rc-2, 2.2.2-RC-1) should > 0 ok 111 - semver(2.2.2-RC-1, 2.2.2-rc-2) should < 0 ok 112 - v2.2.2-rc-2 should be > v2.2.2-RC-1 ok 113 - v2.2.2-rc-2 should be >= v2.2.2-RC-1 ok 114 - v2.2.2-RC-1 should be < v2.2.2-rc-2 ok 115 - v2.2.2-RC-1 should be <= v2.2.2-rc-2 ok 116 - semver(2.2.2-rc-1, 2.2.2-RC-1) should > 0 ok 117 - semver(2.2.2-RC-1, 2.2.2-rc-1) should < 0 ok 118 - v2.2.2-rc-1 should be > v2.2.2-RC-1 ok 119 - v2.2.2-rc-1 should be >= v2.2.2-RC-1 ok 120 - v2.2.2-RC-1 should be < v2.2.2-rc-1 ok 121 - v2.2.2-RC-1 should be <= v2.2.2-rc-1 ok 122 - semver(0.9.10, 0.9.9) should > 0 ok 123 - semver(0.9.9, 0.9.10) should < 0 ok 124 - v0.9.10 should be > v0.9.9 ok 125 - v0.9.10 should be >= v0.9.9 ok 126 - v0.9.9 should be < v0.9.10 ok 127 - v0.9.9 should be <= v0.9.10 ok 128 - semver(1.0.1-1.2.3, 1.0.1-0.9.9.9) should > 0 ok 129 - semver(1.0.1-0.9.9.9, 1.0.1-1.2.3) should < 0 ok 130 - v1.0.1-1.2.3 should be > v1.0.1-0.9.9.9 ok 131 - v1.0.1-1.2.3 should be >= v1.0.1-0.9.9.9 ok 132 - v1.0.1-0.9.9.9 should be < v1.0.1-1.2.3 ok 133 - v1.0.1-0.9.9.9 should be <= v1.0.1-1.2.3 ok 134 - Function to_semver() should exist ok 135 - Function to_semver(text) should exist ok 136 - Function to_semver() should return semver ok 137 - to_semver(1.2.2) should return 1.2.2 ok 138 - to_semver(01.2.2) should return 1.2.2 ok 139 - to_semver(1.02.2) should return 1.2.2 ok 140 - to_semver(1.2.02) should return 1.2.2 ok 141 - to_semver(1.2.02b) should return 1.2.2-b ok 142 - to_semver(1.2.02beta-3 ) should return 1.2.2-beta-3 ok 143 - to_semver(1.02.02rc1) should return 1.2.2-rc1 ok 144 - to_semver(1.0) should return 1.0.0 ok 145 - to_semver(1) should return 1.0.0 ok 146 - to_semver(.0.02) should return 0.0.2 ok 147 - to_semver(1..02) should return 1.0.2 ok 148 - to_semver(1..) should return 1.0.0 ok 149 - to_semver(1.1) should return 1.1.0 ok 150 - to_semver(1.2.b1) should return 1.2.0-b1 ok 151 - to_semver(9.0beta4) should return 9.0.0-beta4 ok 152 - to_semver(9b) should return 9.0.0-b ok 153 - to_semver(rc1) should return 0.0.0-rc1 ok 154 - to_semver() should return 0.0.0 ok 155 - to_semver(..2) should return 0.0.2 ok 156 - to_semver(1.2.3 a) should return 1.2.3-a ok 157 - to_semver(..2 b) should return 0.0.2-b ok 158 - to_semver( 012.2.2) should return 12.2.2 ok 159 - to_semver(20110204) should return 20110204.0.0 ok 160 - to_semver(1.0.0-alpha) should return incoming text ok 161 - to_semver(1.0.0-alpha.1) should return incoming text ok 162 - to_semver(1.0.0-0.3.7) should return incoming text ok 163 - to_semver(1.0.0-x.7.z.92) should return incoming text ok 164 - to_semver(1.0.0-alpha+001) should return incoming text ok 165 - to_semver(1.0.0+20130313144700) should return incoming text ok 166 - to_semver(1.0.0-beta+exp.sha.5114f85) should return incoming text ok 167 - "1.2.0 beta 4" is not a valid semver ok 168 - "1.2.2-" is not a valid semver ok 169 - "1.2.3b#5" is not a valid semver ok 170 - "v1.2.2" is not a valid semver ok 171 - "1.4b.0" is not a valid semver ok 172 - "1v.2.2v" is not a valid semver ok 173 - "1.2.4b.5" is not a valid semver ok 174 - "1.2.3.4" is not a valid semver ok 175 - "1.2.3 4" is not a valid semver ok 176 - "1.2000000000000000.3.4" is not a valid semver ok 177 - max(semver) should work ok 178 - min(semver) should work ok 179 - ORDER BY semver USING < should work ok 180 - ORDER BY semver USING > should work ok 181 - construct to text ok 182 - construct from text ok 183 - construct from bare number ok 184 - construct from numeric ok 185 - construct from bare integer ok 186 - construct from integer ok 187 - construct from bigint ok 188 - construct from smallint ok 189 - construct from decimal ok 190 - construct from real ok 191 - construct from double ok 192 - construct from float ok 193 - cast to text ok 194 - cast from text ok 195 - Cast from bare integer ok 196 - Cast from bare number ok 197 - Cast from numeric ok 198 - Cast from integer ok 199 - Cast from bigint ok 200 - Cast from smallint ok 201 - Cast from decimal ok 202 - Cast from decimal ok 203 - Cast from real ok 204 - Cast from double precision ok 205 - Cast from float ok 206 - Should correctly cast "1.0.0-beta" to text ok 207 - Should correctly cast "1.0.0-beta1" to text ok 208 - Should correctly cast "1.0.0-alpha" to text ok 209 - Should correctly cast "1.0.0-alph" to text ok 210 - Should correctly cast "1.0.0-food" to text ok 211 - Should correctly cast "1.0.0-f111" to text ok 212 - Should correctly cast "1.0.0-f111asbcdasdfasdfasdfasdfasdfasdffasdfadsf" to text ok 213 - "1.0.0+1" is a valid 2.0.0 semver ok 214 - "1.0.0-1+1" is a valid 2.0.0 semver ok 215 - "1.0.0-1.1+1" is a valid 2.0.0 semver ok 216 - "1.0.0-1.1.1.1.1.1.1.1.1.1.1+1.1.1.1.1.1.1.1" is a valid 2.0.0 semver ok 217 - "1.0.0-1.2" is a valid 2.0.0 semver ok 218 - "1.0.0-1.0.2" is a valid 2.0.0 semver ok 219 - "1.0.0-alpha" is a valid 2.0.0 semver ok 220 - "1.0.0-alpha.1" is a valid 2.0.0 semver ok 221 - "1.0.0-0.3.7" is a valid 2.0.0 semver ok 222 - "1.0.0-x.7.z.92" is a valid 2.0.0 semver ok 223 - "0.2.13+1583426134.07de632" is a valid 2.0.0 semver ok 224 - "1.0.0-a.." is not a valid 2.0.0 semver ok 225 - "1.0.0-a.1." is not a valid 2.0.0 semver ok 226 - "1.0.0+1_1" is not a valid 2.0.0 semver ok 227 - "1.0.0-1...." is not a valid 2.0.0 semver ok 228 - "1.0.0-1_2" is not a valid 2.0.0 semver ok 229 - "1.0.0-1.02" is not a valid 2.0.0 semver ok 230 - ORDER BY semver (2.0.0) USING < should work ok 231 - ORDER BY semver (2.0.0) USING > should work ok 232 - semver(1.0.0-1+1, 1.0.0-1+5) should = 0 ok 233 - v1.0.0-1+1 should = v1.0.0-1+5 ok 234 - v1.0.0-1+1 should be <= v1.0.0-1+5 ok 235 - v1.0.0-1+1 should be >= v1.0.0-1+5 ok 236 - semver(1.0.0-1.1+1, 1.0.0-1.1+5) should = 0 ok 237 - v1.0.0-1.1+1 should = v1.0.0-1.1+5 ok 238 - v1.0.0-1.1+1 should be <= v1.0.0-1.1+5 ok 239 - v1.0.0-1.1+1 should be >= v1.0.0-1.1+5 ok 240 - Should correctly represent "0.5.0-release1" as "0.5.0-release1" ok 241 - Should correctly represent "0.5.0release1" as "0.5.0-release1" ok 242 - Should correctly represent "0.5-release1" as "0.5.0-release1" ok 243 - Should correctly represent "0.5release1" as "0.5.0-release1" ok 244 - Should correctly represent "0.5-1" as "0.5.0-1" ok 245 - Should correctly represent "1.2.3-1.02" as "1.2.3-1.2" ok 246 - Function is_semver() should exist ok 247 - Function is_semver(text) should exist ok 248 - Function is_semver() should return boolean ok 249 - is_semver(1.2.2) should return true ok 250 - is_semver(0.2.2) should return true ok 251 - is_semver(0.0.0) should return true ok 252 - is_semver(0.1.999) should return true ok 253 - is_semver(9999.9999999.823823) should return true ok 254 - is_semver(1.0.0-beta1) should return true ok 255 - is_semver(1.0.0-beta2) should return true ok 256 - is_semver(1.0.0) should return true ok 257 - is_semver(1.0.0-1) should return true ok 258 - is_semver(1.0.0-alpha+d34dm34t) should return true ok 259 - is_semver(1.0.0+d34dm34t) should return true ok 260 - is_semver(20110204.0.0) should return true ok 261 - is_semver(1.2) should return false ok 262 - is_semver(1.2.02) should return false ok 263 - is_semver(1.2.2-) should return false ok 264 - is_semver(1.2.3b#5) should return false ok 265 - is_semver(03.3.3) should return false ok 266 - is_semver(v1.2.2) should return false ok 267 - is_semver(1.3b) should return false ok 268 - is_semver(1.4b.0) should return false ok 269 - is_semver(1v) should return false ok 270 - is_semver(1v.2.2v) should return false ok 271 - is_semver(1.2.4b.5) should return false ok 272 - is_semver(2016.5.18-MYW-600) should return true ok 273 - is_semver(1010.5.0+2016-05-27-1832) should return true ok 274 - is_semver(0.2.13+1583426134.07de632) should return true ok 275 - "2.3.0+80" is a valid semver ok 276 - to_semver(2.3.0+80) should return 2.3.0+80 ok 277 - Should correctly cast "2.3.0+80" to text ok 278 - "2.3.0+80" > "2.3.0+110" (NOT!) ok 279 - "2.3.0+80" > "2.3.0-alpha+110" ok 280 - ORDER BY semver USING < should work (section 11) ok 281 - ORDER BY semver USING > should work (section 11) ok 282 - "1.0.0" = "1.0.0+535" ok 283 - "1.0.0" < "1.0.0+535" (NOT!) ok 284 - "1.0.0" > "1.0.0+535" (NOT!) ok 285 - Function get_semver_major() should exist ok 286 - semver ok 287 - Function get_semver_major() should return integer ok 288 - major version check ok 289 - Function get_semver_minor() should exist ok 290 - semver ok 291 - Function get_semver_minor() should return integer ok 292 - minor version check ok 293 - Function get_semver_patch() should exist ok 294 - semver ok 295 - Function get_semver_patch() should return integer ok 296 - patch version check ok 297 - Function get_semver_prerelease() should exist ok 298 - semver ok 299 - Function get_semver_prerelease() should return text ok 300 - prerelease label check ok 301 - prerelease label check. must return prerelease only ok 302 - prerelease label check. must return empty string ok 303 - 1.0.0 should be in range [1.0.0, 2.0.0] ok 304 - 1.0.0 should not be in range [1.0.1, 2.0.0] ok 305 - 2.0.0 should not be in range [1.0.1, 2.0.0) ok 306 - 1.9999.9999 should be in range [1.0.1, 2.0.0) ok 307 - 1000.0.0 should be in range [1.0.0,) ok 308 - Should be able to work with arrays of semverranges ok 309 - Should properly format a 32 character semver ok 310 - Should properly format a 33 character semver ok 311 - Should propery format a prerelease with a hyphen ok 312 - Should get distinct values via hash aggregation ok 313 - Function semver_send() should exist ok 314 - Function semver_send(semver) should exist ok 315 - Function semver_send() should return bytea ok 316 - Function semver_recv() should exist ok 317 - Function semver_recv(internal) should exist ok 318 - Function semver_recv() should return semver ok 319 - semver_send('0.9.9-a1.1+1234') ok 320 - semver_send('0.9.9-a1.2.3') ok 321 - semver_send('0.9.9-a1.2') ok 322 - semver_send('0.9.9') ok 323 - semver_send('1.0.0+99') ok 324 - semver_send('1.0.0-1') ok 325 - semver_send('1.2.2') ok 326 - semver_send('9999.9999999.823823') ok 327 - semver_send('1.0.0-beta1') ok 328 - semver_send('1.0.0-1') ok 329 - semver_send('1.0.0-alpha+d34dm34t') ok 330 - semver_send('1.0.0+d34dm34t') ok 331 - semver_send('20110204.0.0') ok 332 - semver_send('1.0.0-0AEF') ok 333 - semver_send(NULL) ok 334 - Should have binary copied all of the semvers