Changeset 347

Show
Ignore:
Timestamp:
04/16/05 02:01:11 (8 years ago)
Author:
ahu
Message:

add tests to the Makefile
improve tests a bit so it reports success/failure

Location:
trunk/splitpipe
Files:
1 added
2 modified

Legend:

Unmodified
Added
Removed
  • trunk/splitpipe/Makefile

    r344 r347  
    77splitpipe: $(splitpipe_OBJECTS) 
    88        g++ $(splitpipe_OBJECTS) -o $@ 
    9          
     9 
     10 
     11check:  
     12        cd tests; make 
  • trunk/splitpipe/tests/ringbuffer.cc

    r344 r347  
    8282 
    8383  cerr<<"There are now "<<rb.available()<<" bytes available"<<endl; 
     84   
     85  if(rb.available()==0) { 
     86    cerr<<"*** Everything went well!"<<endl; 
     87    exit(EXIT_SUCCESS); 
     88  } 
     89  exit(EXIT_FAILURE); 
    8490} 
    8591catch(exception &e) 
    8692{ 
    8793  cerr<<"error: "<<e.what()<<endl; 
     94  exit(EXIT_FAILURE); 
    8895}