guile-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Testing Functions Internal to a Module


From: Noah Lavine
Subject: Testing Functions Internal to a Module
Date: Sat, 17 Dec 2011 10:07:35 -0500

Hello Guile developers,

I have recently hit an issue and I wish I knew a standard way to handle it.

I want to write tests for a module of mine. Because I like being
paranoid, I'd like to test almost every function in the module. But a
lot of these functions are internal to the module - there's no reason
to export them, except that my test suite needs access to them. So my
choices are to export functions that I don't really want to export, or
to put a bunch of internal module references at the top of my test
program.

Is there a standard way of handling this?

This seems like a place where perhaps a helper procedure would be
useful, because lots of test suites will face this issue. Something
like "import all of this module's private definitions". What does
everyone else do in this situation?

Thanks,
Noah



reply via email to

[Prev in Thread] Current Thread [Next in Thread]