From 279743a20221fb9e3454da889500515d6a2ef785 Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Fri, 19 Nov 2021 17:38:51 -0500
Subject: [PATCH] gnu: ledger: Remove failing test output.
Removes a test which doesn't have output matching the expected (it misses the
leading "./").
* gnu/packages/finance.scm (php)[source]: Add patch.
* gnu/packages/patches/ledger-remove-test.patch: New file.
* gnu/local.mk (dist_patch_DATA): Add it.
---
gnu/local.mk | 1 +
gnu/packages/finance.scm | 4 ++-
gnu/packages/patches/ledger-remove-test.patch | 28 +++++++++++++++++++
3 files changed, 32 insertions(+), 1 deletion(-)
create mode 100644 gnu/packages/patches/ledger-remove-test.patch
@@ -1328,6 +1328,7 @@ dist_patch_DATA = \
%D%/packages/patches/lcalc-lcommon-h.patch \
%D%/packages/patches/lcalc-using-namespace-std.patch \
%D%/packages/patches/ldns-drill-examples.patch \
+ %D%/packages/patches/ledger-remove-test.patch \
%D%/packages/patches/leela-zero-gtest.patch \
%D%/packages/patches/less-hurd-path-max.patch \
%D%/packages/patches/liba52-enable-pic.patch \
@@ -25,6 +25,7 @@
;;; Copyright © 2021 ZmnSCPxj jxPCSnmZ <ZmnSCPxj@protonmail.com>
;;; Copyright © 2021 François J <francois-oss@avalenn.eu>
;;; Copyright © 2021 Foo Chuan Wei <chuanwei.foo@hotmail.com>
+;;; Copyright © 2021 John Kehayias <john.kehayias@protonmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -305,7 +306,8 @@ (define-public ledger
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
- (base32 "0x6jxwss3wwzbzlwmnwb8yzjk8f9wfawif4f1b74z2qg6hc4r7f6"))))
+ (base32 "0x6jxwss3wwzbzlwmnwb8yzjk8f9wfawif4f1b74z2qg6hc4r7f6"))
+ (patches (search-patches "ledger-remove-test.patch"))))
(build-system cmake-build-system)
(arguments
`(#:modules (,@%cmake-build-system-modules
new file mode 100644
@@ -0,0 +1,28 @@
+This test started failing on core-updates-frozen sometime after this commit:
+
+https://git.savannah.gnu.org/cgit/guix.git/log/?id=727f05e1e285aa52f5a19ec923fdc2259859b4b1
+
+It reports the wrong error message, with a lack of a leading "./" in the file name. So it
+passes in that it correctly errors on the missing file, but has the wrong output. This
+patch removes the test file to ignore the test.
+
+diff --git a/test/regress/BF3C1F82-2.test b/test/regress/BF3C1F82-2.test
+deleted file mode 100644
+index a7808504..00000000
+--- a/test/regress/BF3C1F82-2.test
++++ /dev/null
+@@ -1,14 +0,0 @@
+-; Check that include directives are relative for "-f /dev/stdin"
+-include non-existent-ledger-file-BF3C1F82
+-
+-test -f - reg -> 1
+-__ERROR__
+-While parsing file "", line 2:
+-Error: File to include was not found: "./non-existent-ledger-file-BF3C1F82"
+-end test
+-
+-test -f /dev/stdin reg -> 1
+-__ERROR__
+-While parsing file "", line 2:
+-Error: File to include was not found: "./non-existent-ledger-file-BF3C1F82"
+-end test
--
2.33.1