From da1de5cdb5c42ce811a66d377789e585042b98c7 Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Sat, 14 Apr 2012 18:04:52 +0000 Subject: Added support for running subsets of unit tests to Bu::UnitSuite, now just list the names of the tests you want to run on the command line. Also, fixed some minor issues in two of the test suites. --- src/unit/file.unit | 4 ++++ src/unit/variant.unit | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) (limited to 'src/unit') diff --git a/src/unit/file.unit b/src/unit/file.unit index fb04e57..efca4f1 100644 --- a/src/unit/file.unit +++ b/src/unit/file.unit @@ -48,7 +48,11 @@ suite File if( s < 50 ) { unitTest( total == 256 ); + unitTest( sf.isEos() == false ); + unitTest( sf.read( buf, 1 ) == 0 ); unitTest( sf.isEos() == true ); + // EOS is only set when an attempt to read past the end of + // the stream is made, not when a short block is returned. break; } } diff --git a/src/unit/variant.unit b/src/unit/variant.unit index 4fd5e26..53abdc0 100644 --- a/src/unit/variant.unit +++ b/src/unit/variant.unit @@ -55,7 +55,7 @@ suite Variant arg( mkastring().getStr() ). arg( i1, Fmt(2).fill('0') ). arg( i2, Fmt(2).fill('0') ); - sio << sio.nl << out << sio.nl; + // sio << sio.nl << out << sio.nl; unitTest( out == "hello-stuff-32-00.odp" ); } } -- cgit v1.2.3