ATF-devel archive

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

Plain C binding



Hi,

At the moment ATF provides a binding for C/C++ that simplifies the creation of test programs that follow the ATF interface (command line and output format). This "binding" also takes care of many run-time stuff, such as the handling of signals, the creation of temporary directories, etc.

However, this is currently all written in C++. There are multiple macros that hide almost all details of this fact -- you use the macros instead of dealing with classes, exceptions, etc. --, but I think that there can be some resistance in using it to write tests for features that are plain C. (I'm specially afraid of this because of the sudden interest on pcc, which does not support C++.)

What would you think of a plain C binding so that test programs do not need to rely at all on C++? This could restrict all C++ code to the ATF tools and not propagate to tests written by other people (e.g. in our use case, tests that live in the NetBSD source tree). Sure, implementing this will take some time (/me hates C for not having anything to deal with data collections nor strings), but it seems a good idea to me at the moment, specially for the long run.

Any comments?

Thanks,

--
Julio M. Merino Vidal <jmmv84%gmail.com@localhost>





Home | Main Index | Thread Index | Old Index