diff --git a/.github/workflows/ct.yml b/.github/workflows/ct.yml index 14706a2..f38f393 100644 --- a/.github/workflows/ct.yml +++ b/.github/workflows/ct.yml @@ -14,7 +14,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - otp_version: ['25'] + otp_version: ['25', '26', '27'] rebar3_version: ['3.23'] os: [ubuntu-22.04] env: diff --git a/docker-compose.yml b/docker-compose.yml index 417eccc..cffc6d5 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -2,7 +2,7 @@ version: '3.7' services: postgres: - image: cimg/postgres:14.2 + image: postgres:17 environment: - POSTGRES_USER=test - POSTGRES_DB=test diff --git a/rebar.config b/rebar.config index c50c8f7..961cce3 100644 --- a/rebar.config +++ b/rebar.config @@ -2,7 +2,7 @@ {deps, [{backoff, "~> 1.1.6"}, {pg_types, "~> 0.4.0"}, - {opentelemetry_api, "~> 1.3.1"}]}. + {opentelemetry_api, "~> 1.4.0"}]}. {profiles, [{test, [{erl_opts, [nowarn_export_all]}, {deps, [jsone, diff --git a/rebar.lock b/rebar.lock index bec72d6..b96211d 100644 --- a/rebar.lock +++ b/rebar.lock @@ -1,19 +1,11 @@ {"1.2.0", [{<<"backoff">>,{pkg,<<"backoff">>,<<"1.1.6">>},0}, - {<<"opentelemetry_api">>,{pkg,<<"opentelemetry_api">>,<<"1.3.1">>},0}, - {<<"opentelemetry_semantic_conventions">>, - {pkg,<<"opentelemetry_semantic_conventions">>,<<"0.2.0">>}, - 1}, - {<<"pg_types">>,{pkg,<<"pg_types">>,<<"0.4.0">>},0}]}. + {<<"opentelemetry_api">>,{pkg,<<"opentelemetry_api">>,<<"1.4.0">>},0}]}. [ {pkg_hash,[ {<<"backoff">>, <<"83B72ED2108BA1EE8F7D1C22E0B4A00CFE3593A67DBC792799E8CCE9F42F796B">>}, - {<<"opentelemetry_api">>, <<"83B4713593F80562D9643C4AB0B6F80F3C5FA4C6D0632C43E11B2CCB6B04DFA7">>}, - {<<"opentelemetry_semantic_conventions">>, <<"B67FE459C2938FCAB341CB0951C44860C62347C005ACE1B50F8402576F241435">>}, - {<<"pg_types">>, <<"3CE365C92903C5BB59C0D56382D842C8C610C1B6F165E20C4B652C96FA7E9C14">>}]}, + {<<"opentelemetry_api">>, <<"63CA1742F92F00059298F478048DFB826F4B20D49534493D6919A0DB39B6DB04">>}]}, {pkg_hash_ext,[ {<<"backoff">>, <<"CF0CFFF8995FB20562F822E5CC47D8CCF664C5ECDC26A684CBE85C225F9D7C39">>}, - {<<"opentelemetry_api">>, <<"9E8A5CC38671E3AC61BE48ABE5F6B3AFDBBB50A1DC08B7950C56F169611505C1">>}, - {<<"opentelemetry_semantic_conventions">>, <<"D61FA1F5639EE8668D74B527E6806E0503EFC55A42DB7B5F39939D84C07D6895">>}, - {<<"pg_types">>, <<"B02EFA785CAECECF9702C681C80A9CA12A39F9161A846CE17B01FB20AEEED7EB">>}]} + {<<"opentelemetry_api">>, <<"3DFBBFAA2C2ED3121C5C483162836C4F9027DEF469C41578AF5EF32589FCFC58">>}]} ]. diff --git a/src/pgo_handler.erl b/src/pgo_handler.erl index 9b13282..4fd5265 100644 --- a/src/pgo_handler.erl +++ b/src/pgo_handler.erl @@ -339,7 +339,7 @@ setup_finish(Conn=#conn{socket_module=SocketModule, %% set_succeeded_or_within_failed_transaction({error, {error, _} = Error}) -> %% error:is_in_failed_sql_transaction(Error). --spec extended_query(#conn{}, iodata(), list(), pgo:decode_aopts(), any(), list()) -> pgo:result(). +-spec extended_query(#conn{}, iodata(), list(), pgo:decode_opts(), any(), list()) -> pgo:result(). extended_query(Conn=#conn{socket=Socket, socket_module=SocketModule, pool=Pool}, Query, Parameters, DecodeOptions, PerRowFun, Acc0) -> diff --git a/test/certs/privkey.pem b/test/certs/privkey.pem deleted file mode 100644 index 9ed2d86..0000000 --- a/test/certs/privkey.pem +++ /dev/null @@ -1,30 +0,0 @@ ------BEGIN ENCRYPTED PRIVATE KEY----- -MIIFHDBOBgkqhkiG9w0BBQ0wQTApBgkqhkiG9w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OqJ938mGCDVqu61SgK23XlJdKr3fPq8ZpaBBRrWei3xY2pu22aM88mdr2 -1SJQUcRxFVycUpdPDHUKVIK1hliGtwsP8NR3R9AIw9QNh+O6i9S6Maupa/n55U7j -5OJA+AT4A6rjICqAOh3uwVRtKHuQqDCQbNNWsUpuICeHf8LH+dkFzoICKiKfxfTb -sC8Cdtc+rfLCVrYqLdilZvj9b6gFAAQMTVds8vmC725mPNPGoq3w1dGM9Iu7M1oc -YaGCQiv09XIe8TODrpMDoCBzh8cKXUrm6UB6vEPYmhtHFlNjbk4XQ8yJ4qJ/axRX -6atpW3XwaJVa47ht0Y7ZEZzUCBGEg4Cgo56sYcoXCRg2+LS2FPFkB6/2jR0o2K3B -nxfEwOYIeqAPPZq9g4Ov8fEBbBrKfKS/U1dhNEdeZpIETvmQbanEFHJMW6hml6/M -4PQVmH5guVbPOQ0pzKDZhpE6jjclk+M+55DalArUBJTw5Qe4bd3OlT/eD6ANFpvt -7u44unk5anRETlZV+Y/PdqHrra2gOZGRNCPo8Ry6ko19WFEnBPLq0fWixMXFXMdK -3EYTnG0Pl90YLF87coLl3tR5GgSIjmdJo2qzciW4K25uRT6jqUgeuzxKYFKhRY3w -bFADmfbX+jtqlUXm15ijfA== ------END ENCRYPTED PRIVATE KEY----- diff --git a/test/certs/server.crt b/test/certs/server.crt index 1912313..ce18ee7 100644 --- a/test/certs/server.crt +++ b/test/certs/server.crt @@ -1,77 +1,21 @@ -Certificate: - Data: - Version: 3 (0x2) - Serial Number: - 3d:d1:d2:30:e7:90:e5:f4:2d:ab:b9:40:85:8a:b2:f4:48:74:6b:48 - Signature Algorithm: sha256WithRSAEncryption - Issuer: CN = localhost - Validity - Not Before: May 23 14:00:36 2019 GMT - Not After : Jun 22 14:00:36 2019 GMT - Subject: CN = localhost - Subject Public Key Info: - Public Key Algorithm: rsaEncryption - RSA Public-Key: (2048 bit) - Modulus: - 00:b2:e4:16:2a:8f:ae:34:86:10:48:87:07:aa:32: - 6f:b0:e3:c9:87:bc:cf:82:2a:97:49:aa:00:18:6f: - a5:1a:26:d7:96:04:22:f7:d8:8e:6c:24:66:89:09: - 8c:e9:03:28:0b:c8:97:4a:1f:3e:76:83:c5:13:a1: - b6:a2:53:0d:71:74:4a:fb:f4:2f:99:b7:5c:ff:43: - 2b:9d:dd:3f:93:77:05:2c:7a:7a:5f:78:0f:26:85: - b1:44:7b:ce:41:f4:0e:6c:9e:d9:32:bd:68:f7:2f: - 67:58:59:38:62:9a:47:06:97:af:f6:34:3d:f6:3e: - 45:23:64:81:bf:fd:76:13:11:7a:86:11:d6:46:ac: - 9c:6e:23:56:70:c8:b3:27:87:e9:8f:d5:de:55:e9: - 4a:0c:19:78:a0:9e:7d:6c:74:0f:6e:e2:60:36:14: - 40:47:54:b4:f7:8a:df:63:95:02:f0:29:52:ad:ea: - ca:39:cd:2d:6b:8d:61:a7:80:aa:49:33:d0:16:ba: - e4:50:df:7d:54:c3:ab:32:f1:11:de:1b:72:19:5a: - 72:c8:0b:3a:1d:03:d7:ba:6e:b4:2a:fc:ce:a0:7b: - 4a:78:38:9a:11:80:33:71:c1:fd:47:00:f0:c7:dd: - 72:e7:94:da:75:8e:02:42:39:c0:31:dc:d3:24:04: - 9d:7f - Exponent: 65537 (0x10001) - X509v3 extensions: - X509v3 Subject Key Identifier: - 3A:BB:47:90:72:ED:8E:63:37:2F:C8:FA:C3:DF:46:27:C3:FC:8B:0A - X509v3 Authority Key Identifier: - keyid:3A:BB:47:90:72:ED:8E:63:37:2F:C8:FA:C3:DF:46:27:C3:FC:8B:0A - - X509v3 Basic Constraints: critical - CA:TRUE - Signature Algorithm: sha256WithRSAEncryption - 01:87:cc:b8:1a:ec:cd:f5:5a:b3:63:ab:b3:cd:f2:96:12:44: - da:04:79:6b:9f:ae:14:1c:c7:5f:6f:c1:85:99:66:68:5f:a6: - 89:54:0f:36:78:d7:b9:2c:30:68:7d:9c:f6:89:3c:df:33:ba: - c7:46:2e:ca:76:10:73:22:e1:2c:0d:8e:bc:98:b7:95:8c:f2: - 67:d9:60:58:ab:c4:b9:07:8c:a1:c0:85:67:10:a6:a0:26:81: - 75:c8:9c:e7:45:93:f0:f3:d9:14:f4:23:49:b3:75:39:08:25: - 18:56:42:e9:ec:6a:50:d1:da:68:e4:1d:f1:77:84:25:a4:6b: - 9e:4f:f7:e6:ca:f7:9c:bf:61:69:19:89:a9:d5:df:df:5d:31: - b6:0e:ac:c7:35:47:0f:f3:7f:75:f9:51:03:88:15:dd:44:13: - ef:1f:e9:3f:58:ae:77:3a:b6:cb:15:cb:54:80:90:73:40:34: - 1c:50:ba:c7:c7:43:4d:bf:c1:72:16:03:60:85:72:00:77:3e: - 8a:36:3a:18:e2:d6:13:8d:e2:58:80:a7:49:07:05:33:8e:32: - 1c:f0:ae:65:a8:58:eb:03:d8:1a:9a:97:91:a2:c8:23:de:42: - 3e:5c:01:77:fb:ae:dc:7b:e6:ce:bb:0e:d4:bc:ef:03:97:a1: - 74:9f:75:cc -----BEGIN CERTIFICATE----- -MIIDCTCCAfGgAwIBAgIUPdHSMOeQ5fQtq7lAhYqy9Eh0a0gwDQYJKoZIhvcNAQEL -BQAwFDESMBAGA1UEAwwJbG9jYWxob3N0MB4XDTE5MDUyMzE0MDAzNloXDTE5MDYy -MjE0MDAzNlowFDESMBAGA1UEAwwJbG9jYWxob3N0MIIBIjANBgkqhkiG9w0BAQEF -AAOCAQ8AMIIBCgKCAQEAsuQWKo+uNIYQSIcHqjJvsOPJh7zPgiqXSaoAGG+lGibX -lgQi99iObCRmiQmM6QMoC8iXSh8+doPFE6G2olMNcXRK+/Qvmbdc/0Mrnd0/k3cF -LHp6X3gPJoWxRHvOQfQObJ7ZMr1o9y9nWFk4YppHBpev9jQ99j5FI2SBv/12ExF6 -hhHWRqycbiNWcMizJ4fpj9XeVelKDBl4oJ59bHQPbuJgNhRAR1S094rfY5UC8ClS -rerKOc0ta41hp4CqSTPQFrrkUN99VMOrMvER3htyGVpyyAs6HQPXum60KvzOoHtK -eDiaEY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P6VFF9gBHLbnAa7mCauqwBL/HgbD+KE1ApwWDo2eKjKF3EplsEWRG2Z4 +VfgjBYutEe3lwFRryaA2lY13T+XP4N21QpWtI8QLDCUOEL20VWyTSJuNdAIcYA2Y +C8Gx/jxZESdOGivYERM9Y6xUJfxrHGOyw3Cle1P9NuEH2/WcS+IkB/FI90qw/aLi +tCFil38CAwEAAaNTMFEwHQYDVR0OBBYEFE4qKOndgOyPwiajHVCYrKuQQc+hMB8G +A1UdIwQYMBaAFE4qKOndgOyPwiajHVCYrKuQQc+hMA8GA1UdEwEB/wQFMAMBAf8w +DQYJKoZIhvcNAQELBQADggEBACpq1KqSD4FAWDrLX6LhYU0bEF/T1SEuIUwDpzyW ++igYE6Wie+BZOq489qe4eQ32MIyXl0m8ozCCG11SkZHIvsXhglEieJYdNxHmArxW +PdiKjaonaoDVaD2RHwVmaMw3Q5V3ErFTL72RAlwFJPsHMgdAMabR0R33I91YVPie +OTTvYy4gzeXhJ/2HNT657YzMOyUUxZC8OaQGKl7coCh2TjaGlz0O/6jiGE/yPH/I +U5iguxvyYMDiqjW8DRaeL38uVDWXvWWYEJnDX6NiIy21+nnekJvZKHqUY1W0aRFL +D+KdFnfuGca9Vh3LkldpKuKnpcuqPjs692P2qsvezcNS8vs= -----END CERTIFICATE----- diff --git a/test/certs/server.key b/test/certs/server.key index d4efd5e..4119a67 100644 --- a/test/certs/server.key +++ b/test/certs/server.key @@ -1,27 +1,28 @@ ------BEGIN RSA PRIVATE KEY----- -MIIEogIBAAKCAQEAsuQWKo+uNIYQSIcHqjJvsOPJh7zPgiqXSaoAGG+lGibXlgQi -99iObCRmiQmM6QMoC8iXSh8+doPFE6G2olMNcXRK+/Qvmbdc/0Mrnd0/k3cFLHp6 -X3gPJoWxRHvOQfQObJ7ZMr1o9y9nWFk4YppHBpev9jQ99j5FI2SBv/12ExF6hhHW -RqycbiNWcMizJ4fpj9XeVelKDBl4oJ59bHQPbuJgNhRAR1S094rfY5UC8ClSrerK -Oc0ta41hp4CqSTPQFrrkUN99VMOrMvER3htyGVpyyAs6HQPXum60KvzOoHtKeDia -EYAzccH9RwDwx91y55TadY4CQjnAMdzTJASdfwIDAQABAoIBAECjKV83izpvNnL+ -V0an8rN3mtnw3wmpWgDD7EToEj/gyQTrebcUCGIKxQG+8as/+LhJQmEF6QvpkMwH -InaEi9byriVbldd06aVSH/BqgQ5HcxcfKhhUySSiKesU0PIDvTKCMviid8rY1f6W -PklidUdsh6fuOHVBCro/FqLIcmFw1Ch+CYg4S9GqIALdMNexNBWdAwgRLmlF2N0r -p02fzjzepCUDMgomsB2Da87JI7NVJx9OrtScE34cophcKHFMehhdL0TXx7nrZI6U -a37veyggjE1gXWoTdh6UqMBDRylEKzQV7+StadGD07ygtGhnl4kpJ4qhgyXfa/Ny -82FDWAECgYEA6FpC3acwgmikWfSCwVC+47WES+YH/zqONgFvX7qAu5LLh/Ne664u -m7TBLr41irM8LjUBXi1ZOwN3x/lw9hlWD/D7+0ClFANaG74ij0vFNS4lbX+gYKyO -0lv69Vb4HSXd7FxKq31COLSZetSd9XrAmqhKH/mCCgocCAldKfKR9UcCgYEAxRju -QeVYmTjOBE1BO/3a4n4cuMg5Q/WmOI6HoTotJTFmDjBLOMc8/jtP0PfT2oZYGYbc -H48aQmIHaKyw5+7yuufqasVtebtpOxxSCJbjcqGRKtcn9xPoOAcoP/xdLNiW61a6 -V84LUIuKWwEKlM2AelCU7R/tYJ1zUj7/Pbs8EgkCgYBkMhAljyQ/CCrfU65S+KPo -g+zx4ddO+4w5w7KoYD+FI487J/qlvS4CHRc1NfbWweXQszDM0NdquFsd0/YfWduf -8jZnKYBGOg/QaNR0YKNBBI5FQsUBC0hndByrUX6a6ypg84eLne9BjreknS0kn3OQ -/cNBOJIYDDX8TTVsklrYnwKBgAn2ray1HFp6jaeYBDE1Lwh+GZOZw5NU6rc3NVII -L9oOejtDY7oWEFZFx04oCRSl7/QyZhROVqR+ciNvf23qHWknailFm7goqjQrxVXb -0tmrozwILmQGJJ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s69UN7kCJjV4aLhzIHfdB6QfuS1im1dZnKZ +YlUk/ix6qk7JUl2k5HtL7bi13nRFp0dcN7jdAHtvi9FWxDRCEdiU0INLzUmbqj7N +0Gh5Ndvgw4j1zSMkw9ffVucUEwKBgQDpfQm7AAN0TaivppJOcepReAokBHEtw1Bs +vyNsbE8k82j2m+vhzUSS6e4TnGfSqipG6EoND29L39WvPWrcrw97tLmfkbnCvw5o ++74Wl5+n5U/kMPlXOlLYk9UhpRFTuOAFN/3P51AAEmoXctPgfyfvN9aFQyiQTdLd +OVQ826ckZQKBgG5w1uFVmUfwuHCDHy/QitstcBsi8SNbyaCYEWPpICfo/fDR+C0m +0EkNDkIwecInQexbe/Tej6nZV1VmZbH8g9bV2Tq5eA9dCDbN0lMH8dhHohKl5Iy7 +xytuzSWC/C/8ZG6VTnxx8bvSdPPztuUhZGfQoAt09Js1Gt8Xfzl7gDwvAoGAZl7a +K1EgMpfyA8FmmFo9wCZ/W7dO4B+oXWWYZGtAcBUAyk8mpsPW8wr5xUNoCedtzdT+ +0qcXxw6Go+Sru8JNaZGdaSb9aTNXYBQwDbvA1l4mHwiR6fq6ZBa89Zln9WszXVZl +RAhI/R8VwN4po15c5fd3aMo/OLXGZBREqMItkDkCgYEA8295H8YoahfV1aBm6m3x +QZH4uJkSRFSOepGcBkmIoPGdiYJ85+1fmBOeSQPvcQPgynLBTa6iSGbVkp1kCXvM +mPyeNqjcWfh4Gay+fnRjDolc4NZoNVCB0aoyaH+wCZQyPIbGnqspm1piDz0jN7Pp +In+OPiiumI/4hRHC5ZqB5NA= +-----END PRIVATE KEY----- diff --git a/test/certs/server.req b/test/certs/server.req deleted file mode 100644 index 23491b5..0000000 --- a/test/certs/server.req +++ /dev/null @@ -1,60 +0,0 @@ -Certificate Request: - Data: - Version: 1 (0x0) - Subject: CN = localhost - Subject Public Key Info: - Public Key Algorithm: rsaEncryption - RSA Public-Key: (2048 bit) - Modulus: - 00:b2:e4:16:2a:8f:ae:34:86:10:48:87:07:aa:32: - 6f:b0:e3:c9:87:bc:cf:82:2a:97:49:aa:00:18:6f: - a5:1a:26:d7:96:04:22:f7:d8:8e:6c:24:66:89:09: - 8c:e9:03:28:0b:c8:97:4a:1f:3e:76:83:c5:13:a1: - b6:a2:53:0d:71:74:4a:fb:f4:2f:99:b7:5c:ff:43: - 2b:9d:dd:3f:93:77:05:2c:7a:7a:5f:78:0f:26:85: - b1:44:7b:ce:41:f4:0e:6c:9e:d9:32:bd:68:f7:2f: - 67:58:59:38:62:9a:47:06:97:af:f6:34:3d:f6:3e: - 45:23:64:81:bf:fd:76:13:11:7a:86:11:d6:46:ac: - 9c:6e:23:56:70:c8:b3:27:87:e9:8f:d5:de:55:e9: - 4a:0c:19:78:a0:9e:7d:6c:74:0f:6e:e2:60:36:14: - 40:47:54:b4:f7:8a:df:63:95:02:f0:29:52:ad:ea: - ca:39:cd:2d:6b:8d:61:a7:80:aa:49:33:d0:16:ba: - e4:50:df:7d:54:c3:ab:32:f1:11:de:1b:72:19:5a: - 72:c8:0b:3a:1d:03:d7:ba:6e:b4:2a:fc:ce:a0:7b: - 4a:78:38:9a:11:80:33:71:c1:fd:47:00:f0:c7:dd: - 72:e7:94:da:75:8e:02:42:39:c0:31:dc:d3:24:04: - 9d:7f - Exponent: 65537 (0x10001) - Attributes: - a0:00 - Signature Algorithm: sha256WithRSAEncryption - 4a:ff:55:aa:65:d5:0e:8c:cb:32:5f:d2:4f:d7:36:bc:10:fc: - 71:15:1b:d3:1e:f3:e1:ad:40:89:78:cb:04:95:cb:01:1b:08: - 1e:47:88:1e:fa:77:26:1f:ea:b4:2b:2e:5d:82:56:13:1c:ea: - a9:3c:e4:43:f1:23:0d:c7:ce:3d:8c:4a:68:c0:9a:55:78:3b: - ed:54:52:97:74:a2:e6:08:82:59:a9:c6:ec:3f:ca:9c:50:4c: - e8:bb:30:0b:51:b9:1f:4c:14:c3:df:75:44:e9:e1:4e:e1:33: - c8:e5:5d:4e:21:f6:26:68:ff:fe:1b:da:2a:a3:fb:09:c5:24: - 30:5d:95:10:af:52:ea:28:a9:0f:13:77:1e:c7:a1:28:a7:fe: - d8:56:a6:81:c6:82:c0:23:5b:ba:f4:24:63:7e:b8:87:14:58: - 11:ad:5e:05:07:fc:24:fc:d7:ac:bb:ac:fa:f8:fb:8c:0a:62: - cf:1d:12:86:07:75:49:26:69:ce:6e:57:ca:0c:0b:0a:fe:ec: - 83:3f:48:de:33:07:a4:a1:67:b7:46:8d:49:bf:40:9f:c6:5c: - 0b:1e:7e:6d:98:92:84:a4:87:2b:8a:61:33:d3:64:de:99:86: - 7f:41:1e:93:de:d7:d5:29:b8:cb:3f:ea:b6:37:a6:10:e1:92: - 9f:77:40:36 ------BEGIN CERTIFICATE REQUEST----- -MIICWTCCAUECAQAwFDESMBAGA1UEAwwJbG9jYWxob3N0MIIBIjANBgkqhkiG9w0B -AQEFAAOCAQ8AMIIBCgKCAQEAsuQWKo+uNIYQSIcHqjJvsOPJh7zPgiqXSaoAGG+l -GibXlgQi99iObCRmiQmM6QMoC8iXSh8+doPFE6G2olMNcXRK+/Qvmbdc/0Mrnd0/ -k3cFLHp6X3gPJoWxRHvOQfQObJ7ZMr1o9y9nWFk4YppHBpev9jQ99j5FI2SBv/12 -ExF6hhHWRqycbiNWcMizJ4fpj9XeVelKDBl4oJ59bHQPbuJgNhRAR1S094rfY5UC -8ClSrerKOc0ta41hp4CqSTPQFrrkUN99VMOrMvER3htyGVpyyAs6HQPXum60KvzO -oHtKeDiaEYAzccH9RwDwx91y55TadY4CQjnAMdzTJASdfwIDAQABoAAwDQYJKoZI -hvcNAQELBQADggEBAEr/Vapl1Q6MyzJf0k/XNrwQ/HEVG9Me8+GtQIl4ywSVywEb -CB5HiB76dyYf6rQrLl2CVhMc6qk85EPxIw3Hzj2MSmjAmlV4O+1UUpd0ouYIglmp -xuw/ypxQTOi7MAtRuR9MFMPfdUTp4U7hM8jlXU4h9iZo//4b2iqj+wnFJDBdlRCv -UuooqQ8Tdx7HoSin/thWpoHGgsAjW7r0JGN+uIcUWBGtXgUH/CT816y7rPr4+4wK -Ys8dEoYHdUkmac5uV8oMCwr+7IM/SN4zB6ShZ7dGjUm/QJ/GXAsefm2YkoSkhyuK -YTPTZN6Zhn9BHpPe19UpuMs/6rY3phDhkp93QDY= ------END CERTIFICATE REQUEST----- diff --git a/test/pgo_basic_SUITE.erl b/test/pgo_basic_SUITE.erl index e8b8889..b14e307 100644 --- a/test/pgo_basic_SUITE.erl +++ b/test/pgo_basic_SUITE.erl @@ -49,10 +49,21 @@ init_per_group(clear, Config) -> Config; init_per_group(ssl, Config) -> application:ensure_all_started(pgo), - {ok, _} = pgo_sup:start_child(default, #{pool_size => 1, port => 5434, ssl => true, + ssl_options => [{verify_type, verify_peer}, + {cacertfile, "../../../../test/certs/server.crt"}, + {verify_fun, {fun (_, valid, U) -> + {valid, U}; + (_, valid_peer, U) -> + {valid, U}; + (_, {bad_cert, selfsigned_peer}, U) -> + {valid, U}; + (_, Reason, _U) -> + {fail, Reason} + end, []}} + ], database => "test", user => "test", password => "password"}), diff --git a/test/pgo_geometric_SUITE.erl b/test/pgo_geometric_SUITE.erl index db3a30a..5c62604 100644 --- a/test/pgo_geometric_SUITE.erl +++ b/test/pgo_geometric_SUITE.erl @@ -24,7 +24,7 @@ end_per_suite(_Config) -> select(_Config) -> ?assertMatch(#{command := select, - rows := [{#{y := 2.0, x := 0.0}}]}, + rows := [{#{y := 2.0, x := +0.0}}]}, pgo:query("select '(0,2.0)'::point")). insert(_Config) -> @@ -46,5 +46,5 @@ insert(_Config) -> ?assertMatch(#{command := select, rows := [{#{x := 1.1, y := 74.9}}, {#{x := 3.2, y := 4.5}}, - {#{x := 0.0, y := 5.0}}]}, + {#{x := +0.0, y := 5.0}}]}, pgo:query("select a_point from points")).