home.social

#srfi — Public Fediverse posts

Live and recent posts from across the Fediverse tagged #srfi, aggregated by home.social.

  1. There is a Scheme testing framework by Arthur A. Gleckler, which was developed before SRFI-64, but published only in 2020s.

    srfi-email.schemers.org/srfi-d

    1. It's very close to suitbl testing library and SRFI-269 in spirit.
    2. It has a very neat property of saving resumable continuations on failure, so you can explore the problem in recursive REPL having all the local scope available.

  2. We published a new SRFI 269: Portable Test Definitions.

    srfi.schemers.org/srfi-269/

    We already got a very positive feedback from seasoned Scheme hackers, but we also looking forward to yours. We have a few more weeks to incorporate the changes.

    P.S. 21 years have passed since SRFI-64.
    P.P.S. There are links to demo video of the library usage at the end of the SRFI.

    BTW, this huge work is possible thanks to @nlnet and funding they provide!

  3. We were working on SRFI for portable test definitions API for quite some time, and it finally ready.

    Today I made a video quickly explaining the specification and showing an implementation and all cool consequences of the API design.

    youtu.be/JI7Z6-tndaw

    SRFI draft and testing library source code:
    - trop.in/SRFI-268
    - git.sr.ht/~abcdw/guile-ares-rs

  4. I like #UnitTesting. The original #SUnit was wonderful, but it was ported to the land of needless complexity and became #JUnit which begat a whole lot of add on pieces. A simple idea buried under feature creep.

    My favorite testing framework is #SRFI-78 srfi.schemers.org/srfi-78/srfi which provides a little reporting and summarization but it doesn't interfere with the tests. In C the MinUnit header file from Jera Design is beautiful. I use a beefier implementation, again to get simple reporting.

    #Forth has ttester. It is terse to the point that I am tempted to add some reporting. So far I've resisted the temptation.

    As in SRFI-78, you test a phrase and compare against expected results on the stack.

    T{ 1 2 3 drop -> 1 2 }T passes
    T{ 1 2 3 dup -> 1 2 3 }T fails

    I'm writing tests for my library code and use them to test expressions in my AoC efforts.

    I'm trying to decide if I should include the test in the library source (compiled conditionally) or in separate test-* files. #Programming

  5. I like #UnitTesting. The original #SUnit was wonderful, but it was ported to the land of needless complexity and became #JUnit which begat a whole lot of add on pieces. A simple idea buried under feature creep.

    My favorite testing framework is #SRFI-78 srfi.schemers.org/srfi-78/srfi which provides a little reporting and summarization but it doesn't interfere with the tests. In C the MinUnit header file from Jera Design is beautiful. I use a beefier implementation, again to get simple reporting.

    #Forth has ttester. It is terse to the point that I am tempted to add some reporting. So far I've resisted the temptation.

    As in SRFI-78, you test a phrase and compare against expected results on the stack.

    T{ 1 2 3 drop -> 1 2 }T passes
    T{ 1 2 3 dup -> 1 2 3 }T fails

    I'm writing tests for my library code and use them to test expressions in my AoC efforts.

    I'm trying to decide if I should include the test in the library source (compiled conditionally) or in separate test-* files. #Programming

  6. I like #UnitTesting. The original #SUnit was wonderful, but it was ported to the land of needless complexity and became #JUnit which begat a whole lot of add on pieces. A simple idea buried under feature creep.

    My favorite testing framework is #SRFI-78 srfi.schemers.org/srfi-78/srfi which provides a little reporting and summarization but it doesn't interfere with the tests. In C the MinUnit header file from Jera Design is beautiful. I use a beefier implementation, again to get simple reporting.

    #Forth has ttester. It is terse to the point that I am tempted to add some reporting. So far I've resisted the temptation.

    As in SRFI-78, you test a phrase and compare against expected results on the stack.

    T{ 1 2 3 drop -> 1 2 }T passes
    T{ 1 2 3 dup -> 1 2 3 }T fails

    I'm writing tests for my library code and use them to test expressions in my AoC efforts.

    I'm trying to decide if I should include the test in the library source (compiled conditionally) or in separate test-* files. #Programming

  7. I like #UnitTesting. The original #SUnit was wonderful, but it was ported to the land of needless complexity and became #JUnit which begat a whole lot of add on pieces. A simple idea buried under feature creep.

    My favorite testing framework is #SRFI-78 srfi.schemers.org/srfi-78/srfi which provides a little reporting and summarization but it doesn't interfere with the tests. In C the MinUnit header file from Jera Design is beautiful. I use a beefier implementation, again to get simple reporting.

    #Forth has ttester. It is terse to the point that I am tempted to add some reporting. So far I've resisted the temptation.

    As in SRFI-78, you test a phrase and compare against expected results on the stack.

    T{ 1 2 3 drop -> 1 2 }T passes
    T{ 1 2 3 dup -> 1 2 3 }T fails

    I'm writing tests for my library code and use them to test expressions in my AoC efforts.

    I'm trying to decide if I should include the test in the library source (compiled conditionally) or in separate test-* files. #Programming

  8. I like . The original was wonderful, but it was ported to the land of needless complexity and became which begat a whole lot of add on pieces. A simple idea buried under feature creep.

    My favorite testing framework is -78 srfi.schemers.org/srfi-78/srfi which provides a little reporting and summarization but it doesn't interfere with the tests. In C the MinUnit header file from Jera Design is beautiful. I use a beefier implementation, again to get simple reporting.

    has ttester. It is terse to the point that I am tempted to add some reporting. So far I've resisted the temptation.

    As in SRFI-78, you test a phrase and compare against expected results on the stack.

    T{ 1 2 3 drop -> 1 2 }T passes
    T{ 1 2 3 dup -> 1 2 3 }T fails

    I'm writing tests for my library code and use them to test expressions in my AoC efforts.

    I'm trying to decide if I should include the test in the library source (compiled conditionally) or in separate test-* files.

  9. In GNU Guile, cond-expand knows of supported features that are not built into GNU Guile only once I have already imported the libraries in which the features are implemented, where cond-expand-provide is being used to define a cond-expand feature.

    Why bother using cond-expand-provide if it will run only after you already have imported something?

    It is the chicken and the egg problem, or something.

    AH JUS DUN GAE ET.

    #gnuguile #guile #guix #lisp #programming #scheme #srfi

  10. I made the tackiest logo I could think of for this kakafarm-guix-stuff Codeberg organisation.

    It is probably illegal, too, being made of some schmoe's artwork. Would have to replace it with something else in the future.

    https://codeberg.org/kakafarm-guix-stuff/

    #armwrestling
    #arnoldschwarzenegger
    #carlweathers
    #dillonyousonofabitch
    #guile
    #guix
    #handshake
    #kakafarm
    #srfi
    #tacky
    #thepredator
  11. Hot take: in terms of the language specified treated independently of the social process of standardization itself, everyone's beloved #r5rs is actually the worst post-#r4rs scheme, and #r6rs is easily the best and most revolutionary, hence the controversy surrounding it.

    #lisp #srfi

  12. SRFIs are modules, which are portable across different scheme implementations, also there is a process for proposing them. BTW, guile contains only subset of it.

    ice-9 are basically guile modules, which could be (guile ...), but they are (ice-9 ...).

    srfi.schemers.org/srfi-process

    lists.gnu.org/archive/html/gui

  13. Just had a (certainly unoriginal) idea for "named match", which extends the Shinn patter matcher to behave like named let. Quick and dirty prototype came together quickly with syntax-case.

    #lisp #scheme #macros #r7rs #srfi #guix

  14. #SRFI-165 (environment monad) is great because it allows you to do all the fun-yet-dirty stuff you can do with `eval` in a safe (interaction-environment) that you have precise control over

  15. Do someone have a good test running setup for ?

    , , -64,

    I hacked something like this, but there is a way more work to make it any satisfactory.

  16. @jeko Quite a few, for #r7rs #scheme. Almost obligatory are:

    * #srfi 27 for random numbers
    * srfi 152 for string functions
    * srfi 64 for tests
    * srfi 117 for the list-queue structure
    * srfi 1 for lists, of course
    * srfi 125 for hash-table (nearly forgot this one!)
    * with srfi 128 for comparators.

    And I'm trying to learn how to use:

    * srfi 115 for regular expressions
    * srfi 159 for show/formatting