Subject: [bug#52186] [core-updates-frozen PATCH v2 04/17] gnu: julia-finitedifferences: Fix tests on i686-linux.

From: zimoun <[email-masked]>
Date: Wed, 1 Dec 2021 16:53:50 +0100

* gnu/packages/julia-xyz (julia-finitedifferences)[arguments]<#:phases>:
Conditionnally disable the failing test.
---
 gnu/packages/julia-xyz.scm | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/gnu/packages/julia-xyz.scm b/gnu/packages/julia-xyz.scm
index d668924bf7..f5d2f69997 100644
--- a/gnu/packages/julia-xyz.scm
+++ b/gnu/packages/julia-xyz.scm
@@ -1685,6 +1685,18 @@ (define-public julia-finitedifferences
        (sha256
         (base32 "09nsf9cgk49yrvprflnhd9h5rrgs280rgj8sad3csghxdx6jqk5c"))))
     (build-system julia-build-system)
+    (arguments
+     `(#:phases
+       ,@(if (string-prefix? "i686" (or (%current-target-system)
+                                        (%current-system)))
+             '((modify-phases %standard-phases
+                 (add-after 'unpack 'remove-failing-test-i686
+                   (lambda _
+                     ;; Machine Precision incorrectly handled
+                     (substitute* "test/methods.jl"
+                       (("@test central_fdm\\(15, 5, adapt=2\\)\\(exp, 1.0\\)")
+                        "@test_broken central_fdm(15, 5, adapt=2)(exp, 1.0)"))))))
+             '(%standard-phases))))
     (inputs
      `(("julia-benchmarktools" ,julia-benchmarktools)))
     (propagated-inputs
-- 
2.32.0