IRC channel logs

2022-10-16.log

back to list of logs

***Colere is now known as Sauvin
***help is now known as roptat
<stis>hey guilers!
<Zelphir>Hello! Sorry, if I missed any previous answer to this question: How do you use SRFI-64 (unit tests) test-group and test-begin/end ? Do you nest them at all? What is the proper way to use them?
<xd1le>Zelphir, it doesn't look like anyone answered your question. Public log is available at https://logs.guix.gnu.org/guile btw.
*xd1le doesn't know
<Zelphir>Ah, didn't know about the log! Thanks!
<Zelphir>How can I get the current working directory inside a Guile REPL? I know about (chdir ...), but there is no (cwd) or (pwd) and (current-<press tab here> does not yield anything for that.
<ft>(getcwd)
<Zelphir>Ah thank you!
<old>After sending a patch to a xxxxx@debbugs.gnu.org, do I have to do anything to get it merged? Should I notify someone?
<old>Zelphir: I think that test-group is a syntax around a pair of test-begin/test-end
<old>Typically, I will use test-begin and test-end once for a file. Usually it describe the module I'm testing.
<old>Then I will use test-group for thing that can be grouped together. For example, tests that are only for x86-64 would form a group.
<old>The advantage is that you can skip a group with `(test-skip "x86-64")` for example when you're testing for another architecture.
<old>But hey that's my usage of srfi-64, you can do anything that please you!
<unmatched-paren>old: I believe debbugs automatically notifies the Guix maintainers when you send a Guix ticket, so it's probably the same for Guile
<old>unmatched-paren: Awesome thanks
<Zelphir>old: Thanks!
<Zelphir>I think I've done it the other way around in previous projects, the test-begin/end on the outermost level and inside a test-group. I found out today, that one can also nest test-groups without adding more test-begin/end s. Seems like almost any combination works. Just not so sure about the semantics and how it is supposed to be used.
<Zelphir>Is there a way to match a lambda like (lambda (a b c) ...) and a lambda with rest arguments like (lambda (a b . cs) ...) with the same expression in a macro? (_ a b c) does not seem to match the one with rest arguments.
<old>(_ (lambda (a b c ...) body body* ...)) ?
<Zelphir>That also does not match. So far only writing the pattern with the dot like (_ (a b . c) body body* ...) worked.