Mark Hindess wrote:
> On 24 January 2007 at 15:58, "Spark Shen" <[EMAIL PROTECTED]> wrote:
>> Hi All:
>>
>> As I said previously, I want to write some native unit tests. Now, all
>> of the native test code are of the following 2 forms:
>> 1. native mains
>> 2. java mains + jni methods
>>
>> How about introduce some automatic unit test tools such as CUNIT,
>> NUNIT etc into our test framework? Is there any licence problem?
>> AFAIK, CUNIT is of GPL licence and NUNIT is of zlib.
> 
>> IMHO, they both are ok.Since we only use them as dll not as source
>> code.  Your opinion?
> 
> What are you hoping to test?  I think as much as possible should be
> tested from Java.  I'm only treating the the portlib as "special"
> because that is where the majority of the platform-specific code is (or
> at least should be!).  Thus having portlib tests really helps porting
> when you don't yet have a VME.

Not only that, but the portlib functions are designed to be called from
C so writing unit tests for them in C makes sense; whereas the Java
natives are designed to be called from Java and you'll have all sorts of
fun setting up the JNIEnv and faking a VM to unit test them from a C
program.

Regards,
Tim

Reply via email to