home *** CD-ROM | disk | FTP | other *** search
/ QBasic & Borland Pascal & C / Delphi5.iso / C / BC_502 / ADDON.PAK / MSGTEST.H < prev    next >
Encoding:
C/C++ Source or Header  |  1997-05-06  |  1.3 KB  |  55 lines

  1. /*:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
  2.  
  3.    Created: 1/3/96
  4.    Copyright (c) 1987, 1996 Borland International Inc.  All Rights Reserved.
  5.    $Revision:   1.12  $
  6.  
  7. :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::*/ 
  8.  
  9. #ifndef __MSGTEST_H
  10. #define __MSGTEST_H
  11.  
  12. #include <ideaddon\imsgsys.h>
  13. #include "tests.h"
  14.  
  15. struct GenericMessageFolder {
  16.   GenericMessageFolder(LPCSTR name);
  17.   void OpenFile(LPCSTR fileName, LPCSTR msg);
  18.   void Log(LPCSTR msg);
  19.  
  20.   DWORD CreatePipedProcess(LPSTR commandLine);
  21.   VOID  ReadFromPipe(HANDLE hFile);
  22.   BOOL  WriteMessage(LPSTR chBuf, DWORD dwRead, DWORD* dwWritten);
  23.   void  Run();
  24.   unsigned DoThread(LPCSTR cmd);
  25.  
  26.  
  27. protected:
  28.   IMessageFolder* d_folder;
  29.   HMSGITEM        d_msgItem;
  30.   LPCSTR          d_currentCmd;
  31. };
  32.  
  33.  
  34. class MsgSystemTest : public TestObject {
  35.  public:
  36.   MsgSystemTest();
  37.   ~MsgSystemTest();
  38.  
  39.   //........ TestObject Methods .......
  40.   virtual BOOL Init();
  41.   virtual void UnInit();  
  42.   virtual const char * GetName();
  43.   virtual const char * GetTestDescription( int testNum );
  44.   virtual void DoTest( int testNum );
  45.  
  46.  protected:
  47.   GenericMessageFolder* d_msgFolder1;
  48.   GenericMessageFolder* d_msgFolder2;
  49.  
  50. }; 
  51.  
  52.  
  53.  
  54. #endif // __MSGTEST_H
  55.