diff options
| author | Sharlatan Hellseher <sharlatanus@gmail.com> | 2026-08-22 22:53:15 +0100 |
|---|---|---|
| committer | Sharlatan Hellseher <sharlatanus@gmail.com> | 2026-08-22 22:53:50 +0100 |
| commit | 588c6a2a756974264d7b253791c5af7842d8c139 (patch) | |
| tree | c9fb2581a2af3c77d49ee250c6c8bef4ce7ad0fc | |
| parent | 22aba16f7d8704d899328c7051f483245dd36c42 (diff) | |
gnu: mysql-connector-python: Fix tests.
* gnu/packages/databases.scm (mysql-connector-python):
[phases]{regenerate-certificate}: New phase; certificate were expired
regenerate them before running tests with provided script.
| -rw-r--r-- | gnu/packages/databases.scm | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index f03a817f346..b57382caa2e 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm | |||
| @@ -1250,6 +1250,18 @@ Language.") | |||
| 1250 | ;; Our protobuf is too old for the mysqlx dev API, so use the | 1250 | ;; Our protobuf is too old for the mysqlx dev API, so use the |
| 1251 | ;; classic one without the C modules. | 1251 | ;; classic one without the C modules. |
| 1252 | (chdir "mysql-connector-python"))) | 1252 | (chdir "mysql-connector-python"))) |
| 1253 | (add-before 'check 'regenerate-certificate | ||
| 1254 | (lambda* (#:key inputs outputs #:allow-other-keys) | ||
| 1255 | (with-directory-excursion "tests/data/ssl" | ||
| 1256 | (substitute* "./generate.sh" | ||
| 1257 | (("which openssl") | ||
| 1258 | (search-input-file inputs "bin/openssl")) | ||
| 1259 | (("\\$OPENSSL") | ||
| 1260 | (search-input-file inputs "bin/openssl"))) | ||
| 1261 | ;; Use `make-file-executable' from guix/guix!7224 after | ||
| 1262 | ;; core-packages-team is merged. | ||
| 1263 | (chmod "./generate.sh" #o555) | ||
| 1264 | (invoke "./generate.sh")))) | ||
| 1253 | (replace 'check | 1265 | (replace 'check |
| 1254 | (lambda* (#:key tests? #:allow-other-keys) | 1266 | (lambda* (#:key tests? #:allow-other-keys) |
| 1255 | (when tests? | 1267 | (when tests? |
| @@ -1259,7 +1271,8 @@ Language.") | |||
| 1259 | (mkdir-p "/tmp/datadir") | 1271 | (mkdir-p "/tmp/datadir") |
| 1260 | (invoke "python3" "unittests.py" | 1272 | (invoke "python3" "unittests.py" |
| 1261 | "--verbosity=3" | 1273 | "--verbosity=3" |
| 1262 | (string-append "--with-mysql=" #$(this-package-input "mysql")) | 1274 | (string-append "--with-mysql=" |
| 1275 | #$(this-package-input "mysql")) | ||
| 1263 | "--keep" | 1276 | "--keep" |
| 1264 | "--mysql-topdir=/tmp/datadir" | 1277 | "--mysql-topdir=/tmp/datadir" |
| 1265 | "--unix-socket=/tmp/datadir"))))))) | 1278 | "--unix-socket=/tmp/datadir"))))))) |
