unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
* Extending new srfi-64 (yay!) and missing file:line: FAIL?
@ 2024-11-05  8:14 janneke
  0 siblings, 0 replies; only message in thread
From: janneke @ 2024-11-05  8:14 UTC (permalink / raw)
  To: guile-user

Hi,

I found that new srfi-64 luckily can be easily extended to take custom
equality functions, yay!...if only %test-2 was exported...

Also, jumping to the test location from the compilation buffer broke for
me. So I'm now carrying this patch now.

Maybe I am missing something, is there a better way?

Greetings,
Janneke

--8<---------------cut here---------------start------------->8---
diff --git a/module/srfi/srfi-64.scm b/module/srfi/srfi-64.scm
index 98fcef645f..8bc892d7aa 100644
--- a/module/srfi/srfi-64.scm
+++ b/module/srfi/srfi-64.scm
@@ -115,6 +115,7 @@
    test-runner-xpass-count
 
    ;; Additional functionality not in SRFI-64:
+   %test-2
    define-test
    test-procedure?
    test-thunk
@@ -435,8 +436,9 @@ instead."
               result-kind
               (test-runner-test-name runner))
       (unless (member result-kind '(pass xfail))
-        (maybe-print-prop 'source-file    #f)
-        (maybe-print-prop 'source-line    #f)
+        (format #t "~a:~a: FAIL\n"
+                (test-result-ref runner 'source-file)
+                (test-result-ref runner 'source-line))
         (maybe-print-prop 'source-form    #t)
         (maybe-print-prop 'expected-value #f)
         (maybe-print-prop 'expected-error #t)
--8<---------------cut here---------------end--------------->8---

-- 
Janneke Nieuwenhuizen <janneke@gnu.org>  | GNU LilyPond https://LilyPond.org
Freelance IT https://www.JoyOfSource.com | Avatar® https://AvatarAcademy.com



^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2024-11-05  8:14 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-11-05  8:14 Extending new srfi-64 (yay!) and missing file:line: FAIL? janneke

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).