summary refs log tree commit diff
path: root/pkgs/development/python-modules/pyopenssl
diff options
context:
space:
mode:
authorRobert Scott <code@humanleg.org.uk>2019-05-01 00:51:36 +0100
committerFrederik Rietdijk <freddyrietdijk@fridh.nl>2019-05-12 20:01:58 +0200
commit3e9184b8dcfa6fe9f23e2ccd545fdd5fd6a7f8ec (patch)
tree73a53015559c4fe785cbf9951ca748c209d2080e /pkgs/development/python-modules/pyopenssl
parent0ffe8e6bb1597fd77eceea4c59e6ab461f852877 (diff)
downloadnixpkgs-3e9184b8dcfa6fe9f23e2ccd545fdd5fd6a7f8ec.tar
nixpkgs-3e9184b8dcfa6fe9f23e2ccd545fdd5fd6a7f8ec.tar.gz
nixpkgs-3e9184b8dcfa6fe9f23e2ccd545fdd5fd6a7f8ec.tar.bz2
nixpkgs-3e9184b8dcfa6fe9f23e2ccd545fdd5fd6a7f8ec.tar.lz
nixpkgs-3e9184b8dcfa6fe9f23e2ccd545fdd5fd6a7f8ec.tar.xz
nixpkgs-3e9184b8dcfa6fe9f23e2ccd545fdd5fd6a7f8ec.tar.zst
nixpkgs-3e9184b8dcfa6fe9f23e2ccd545fdd5fd6a7f8ec.zip
pythonPackages.pyopenssl: add support for building with openssl 1.1.x
Diffstat (limited to 'pkgs/development/python-modules/pyopenssl')
-rw-r--r--pkgs/development/python-modules/pyopenssl/default.nix15
1 files changed, 14 insertions, 1 deletions
diff --git a/pkgs/development/python-modules/pyopenssl/default.nix b/pkgs/development/python-modules/pyopenssl/default.nix
index 7bc54cb0ffb..713861deae3 100644
--- a/pkgs/development/python-modules/pyopenssl/default.nix
+++ b/pkgs/development/python-modules/pyopenssl/default.nix
@@ -32,12 +32,25 @@ let
     "test_set_notBefore"
   ];
 
+  # these tests are extremely tightly wed to the exact output of the openssl cli tool,
+  # including exact punctuation.
+  failingOpenSSL_1_1Tests = [
+    "test_dump_certificate"
+    "test_dump_privatekey_text"
+    "test_dump_certificate_request"
+    "test_export_text"
+  ];
+
   disabledTests = [
     # https://github.com/pyca/pyopenssl/issues/692
     # These tests, we disable always.
     "test_set_default_verify_paths"
     "test_fallback_default_verify_paths"
-  ] ++ (optionals (hasPrefix "libressl" openssl.meta.name) failingLibresslTests);
+  ] ++ (
+    optionals (hasPrefix "libressl" openssl.meta.name) failingLibresslTests
+  ) ++ (
+    optionals (versionAtLeast (getVersion openssl.name) "1.1") failingOpenSSL_1_1Tests
+  );
 
   # Compose the final string expression, including the "-k" and the single quotes.
   testExpression = optionalString (disabledTests != [])