diff options
| author | Baptiste Lepilleur <gaiacrtn@free.fr> | 2002-05-22 16:27:26 +0000 |
|---|---|---|
| committer | Baptiste Lepilleur <gaiacrtn@free.fr> | 2002-05-22 16:27:26 +0000 |
| commit | 7edd0684368ed3c43fe2707d1d34d6b7590d9fd6 (patch) | |
| tree | 7da10dc7bf683242741009a71fd216a3390c650b | |
| parent | a882d92fce563e1d0612f16cfa48956fe904d92b (diff) | |
| download | cppunit-7edd0684368ed3c43fe2707d1d34d6b7590d9fd6.tar.gz | |
Src/msvc6/testrunner/MsDevCallerListCtrl.
src/msvc6/testrunner/MsDevCallerListCtrl.h:
* src/msvc6/testrunner/MsDevCallerListCtrl.cpp:
* src/msvc6/testrunner/Resource.h:
* src/msvc6/testrunner/TestRunner.rc:
* src/msvc6/testrunner/TestRunnerDlg.cpp:
* src/msvc6/testrunner/TestRunnerModel.h:
* src/msvc6/testpluginrunner/TestPlugInRunner.rc:
* src/msvc6/testpluginrunner/TestPlugInRunnerDlg.cpp:
* src/msvc6/testpluginrunner/TestPlugInRunnerDlg.h:
* src/msvc6/testpluginrunner/TestPlugInRunnerModel.cpp: integrated patch from
Marco Welti (Welti@GretagMacbeth.ch) with a few clean up.
Display the name of the test being run during above the progress bar. Allow the
VC++ add-ins to works with TestPlugInRunner (COM init). DLL name can be specified
on the command line after flag '-testsuite'. Display wait cursor, clear and reload
history when reloading DLL.
* THANKS: added Marco Welti to the list.
| -rw-r--r-- | ChangeLog | 20 | ||||
| -rw-r--r-- | THANKS | 3 | ||||
| -rw-r--r-- | examples/examples.opt | bin | 147968 -> 146944 bytes | |||
| -rw-r--r-- | src/cppunit/cppunit.dsp | 4 | ||||
| -rw-r--r-- | src/msvc6/testpluginrunner/Resource.h | 9 | ||||
| -rw-r--r-- | src/msvc6/testpluginrunner/TestPlugInRunner.dsp | 20 | ||||
| -rw-r--r-- | src/msvc6/testpluginrunner/TestPlugInRunner.rc | 3 | ||||
| -rw-r--r-- | src/msvc6/testpluginrunner/TestPlugInRunnerDlg.cpp | 159 | ||||
| -rw-r--r-- | src/msvc6/testpluginrunner/TestPlugInRunnerDlg.h | 46 | ||||
| -rw-r--r-- | src/msvc6/testpluginrunner/TestPlugInRunnerModel.cpp | 4 | ||||
| -rw-r--r-- | src/msvc6/testrunner/MsDevCallerListCtrl.cpp | 3 | ||||
| -rw-r--r-- | src/msvc6/testrunner/MsDevCallerListCtrl.h | 1 | ||||
| -rw-r--r-- | src/msvc6/testrunner/Resource.h | 3 | ||||
| -rw-r--r-- | src/msvc6/testrunner/TestRunner.dsp | 4 | ||||
| -rw-r--r-- | src/msvc6/testrunner/TestRunner.rc | 5 | ||||
| -rw-r--r-- | src/msvc6/testrunner/TestRunnerDlg.cpp | 3 | ||||
| -rw-r--r-- | src/msvc6/testrunner/TestRunnerModel.h | 2 |
17 files changed, 183 insertions, 106 deletions
@@ -1,3 +1,23 @@ +2002-05-21 Baptiste Lepilleur <gaiacrtn@free.fr> + + * src/msvc6/testrunner/MsDevCallerListCtrl.h: + * src/msvc6/testrunner/MsDevCallerListCtrl.cpp: + * src/msvc6/testrunner/Resource.h: + * src/msvc6/testrunner/TestRunner.rc: + * src/msvc6/testrunner/TestRunnerDlg.cpp: + * src/msvc6/testrunner/TestRunnerModel.h: + * src/msvc6/testpluginrunner/TestPlugInRunner.rc: + * src/msvc6/testpluginrunner/TestPlugInRunnerDlg.cpp: + * src/msvc6/testpluginrunner/TestPlugInRunnerDlg.h: + * src/msvc6/testpluginrunner/TestPlugInRunnerModel.cpp: integrated patch from + Marco Welti (Welti@GretagMacbeth.ch) with a few clean up. + Display the name of the test being run during above the progress bar. Allow the + VC++ add-ins to works with TestPlugInRunner (COM init). DLL name can be specified + on the command line after flag '-testsuite'. Display wait cursor, clear and reload + history when reloading DLL. + + * THANKS: added Marco Welti to the list. + 2002-05-07 Baptiste Lepilleur <gaiacrtn@free.fr> * src/DllPlugInTester/CommandLineParser.cpp: fixed compilation issue. @@ -11,4 +11,5 @@ Jeffrey Morgan <kuzman@zoominternet.net> 'cuppa' project team (http://sourceforge.jp/projects/cuppa/) Phil Verghese <philv@users.sourceforge.net> Lavoie Philippe <lavoie@yukon.genie.uottawa.ca> -Pavel Zabelin
\ No newline at end of file +Pavel Zabelin +Marco Welti <Welti@GretagMacbeth.ch>
\ No newline at end of file diff --git a/examples/examples.opt b/examples/examples.opt Binary files differindex 998ea28..6131983 100644 --- a/examples/examples.opt +++ b/examples/examples.opt diff --git a/src/cppunit/cppunit.dsp b/src/cppunit/cppunit.dsp index 7215e49..d33cc04 100644 --- a/src/cppunit/cppunit.dsp +++ b/src/cppunit/cppunit.dsp @@ -113,6 +113,10 @@ SOURCE=..\..\doc\other_documentation.dox # End Source File # Begin Source File +SOURCE=..\..\THANKS +# End Source File +# Begin Source File + SOURCE=..\..\TODO # End Source File # End Group diff --git a/src/msvc6/testpluginrunner/Resource.h b/src/msvc6/testpluginrunner/Resource.h index 7aa669e..6a6c527 100644 --- a/src/msvc6/testpluginrunner/Resource.h +++ b/src/msvc6/testpluginrunner/Resource.h @@ -18,14 +18,15 @@ #define IDC_EDIT_TIME 1010 #define IDC_BROWSE_TEST 1011 #define IDC_CHECK_AUTORUN 1013 +#define IDC_RUNNING_TEST_CASE_LABEL 1016 // Next default values for new objects // #ifdef APSTUDIO_INVOKED #ifndef APSTUDIO_READONLY_SYMBOLS -#define _APS_NEXT_RESOURCE_VALUE 129 -#define _APS_NEXT_COMMAND_VALUE 32771 -#define _APS_NEXT_CONTROL_VALUE 1005 -#define _APS_NEXT_SYMED_VALUE 101 +#define _APS_NEXT_RESOURCE_VALUE 130 +#define _APS_NEXT_COMMAND_VALUE 32772 +#define _APS_NEXT_CONTROL_VALUE 1018 +#define _APS_NEXT_SYMED_VALUE 103 #endif #endif diff --git a/src/msvc6/testpluginrunner/TestPlugInRunner.dsp b/src/msvc6/testpluginrunner/TestPlugInRunner.dsp index b466494..2b57ef9 100644 --- a/src/msvc6/testpluginrunner/TestPlugInRunner.dsp +++ b/src/msvc6/testpluginrunner/TestPlugInRunner.dsp @@ -217,15 +217,7 @@ InputName=cppunit_dll !ELSEIF "$(CFG)" == "TestPlugInRunner - Win32 Debug" -# Begin Custom Build - Updating $(InputPath) -IntDir=.\Debug -InputPath=..\..\..\lib\cppunit_dll.dll -InputName=cppunit_dll - -"$(IntDir)\$(InputName).dll" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)" - copy $(InputPath) $(IntDir)\$(InputName).dll - -# End Custom Build +# PROP Exclude_From_Build 1 !ENDIF @@ -279,17 +271,7 @@ InputName=testrunner # Begin Source File SOURCE=..\..\..\lib\testrunnercd.dll - -!IF "$(CFG)" == "TestPlugInRunner - Win32 Release" - -# PROP Exclude_From_Build 1 - -!ELSEIF "$(CFG)" == "TestPlugInRunner - Win32 Debug" - # PROP Exclude_From_Build 1 - -!ENDIF - # End Source File # Begin Source File diff --git a/src/msvc6/testpluginrunner/TestPlugInRunner.rc b/src/msvc6/testpluginrunner/TestPlugInRunner.rc index f66776c..f75fc9d 100644 --- a/src/msvc6/testpluginrunner/TestPlugInRunner.rc +++ b/src/msvc6/testpluginrunner/TestPlugInRunner.rc @@ -40,7 +40,7 @@ BEGIN BS_AUTOCHECKBOX | BS_MULTILINE | WS_TABSTOP,347,67,49,25 PUSHBUTTON "&Stop",ID_STOP,346,175,50,14 PUSHBUTTON "&Close",IDOK,346,194,50,14 - LTEXT "Progress:",IDC_STATIC,7,38,49,9 + LTEXT "Progress:",IDC_STATIC,7,38,31,9 LTEXT "Runs:",IDC_STATIC,103,76,29,10 LTEXT "0",IDC_STATIC_RUNS,141,76,19,8 LTEXT "Errors:",IDC_STATIC,169,76,29,10 @@ -53,6 +53,7 @@ BEGIN EDITTEXT IDC_EDIT_TIME,7,195,332,13,ES_AUTOHSCROLL | ES_READONLY PUSHBUTTON "&Choose DLL",IDC_CHOOSE_DLL,346,97,50,14 PUSHBUTTON "Re&load DLL",IDC_RELOAD_DLL,346,122,50,14 + LTEXT "none",IDC_RUNNING_TEST_CASE_LABEL,40,38,299,8 END diff --git a/src/msvc6/testpluginrunner/TestPlugInRunnerDlg.cpp b/src/msvc6/testpluginrunner/TestPlugInRunnerDlg.cpp index 0f1aaba..cf8d566 100644 --- a/src/msvc6/testpluginrunner/TestPlugInRunnerDlg.cpp +++ b/src/msvc6/testpluginrunner/TestPlugInRunnerDlg.cpp @@ -5,6 +5,7 @@ #include "TestPlugInRunnerDlg.h" #include "TestPlugIn.h" #include "TestPlugInException.h" +#include <algorithm> #ifdef _DEBUG #define new DEBUG_NEW @@ -16,31 +17,33 @@ static char THIS_FILE[] = __FILE__; // TestPlugInRunnerDlg dialog TestPlugInRunnerDlg::TestPlugInRunnerDlg( TestPlugInRunnerModel *model, - CWnd* pParent ) : - TestRunnerDlg( model, IDD_TEST_PLUG_IN_RUNNER, pParent ) + CWnd* pParent ) + : TestRunnerDlg( model, IDD_TEST_PLUG_IN_RUNNER, pParent ) { - //{{AFX_DATA_INIT(TestPlugInRunnerDlg) - // NOTE: the ClassWizard will add member initialization here - //}}AFX_DATA_INIT - // Note that LoadIcon does not require a subsequent DestroyIcon in Win32 - m_hIcon = AfxGetApp()->LoadIcon(IDR_TEST_PLUGIN_RUNNER); + //{{AFX_DATA_INIT(TestPlugInRunnerDlg) + // NOTE: the ClassWizard will add member initialization here + //}}AFX_DATA_INIT + // Note that LoadIcon does not require a subsequent DestroyIcon in Win32 + m_hIcon = AfxGetApp()->LoadIcon(IDR_TEST_PLUGIN_RUNNER); } -void TestPlugInRunnerDlg::DoDataExchange(CDataExchange* pDX) + +void +TestPlugInRunnerDlg::DoDataExchange( CDataExchange* pDX ) { - TestRunnerDlg::DoDataExchange(pDX); - //{{AFX_DATA_MAP(TestPlugInRunnerDlg) - // NOTE: the ClassWizard will add DDX and DDV calls here - //}}AFX_DATA_MAP + TestRunnerDlg::DoDataExchange(pDX); + //{{AFX_DATA_MAP(TestPlugInRunnerDlg) + // NOTE: the ClassWizard will add DDX and DDV calls here + //}}AFX_DATA_MAP } BEGIN_MESSAGE_MAP(TestPlugInRunnerDlg, TestRunnerDlg) - //{{AFX_MSG_MAP(TestPlugInRunnerDlg) - ON_WM_PAINT() - ON_WM_QUERYDRAGICON() - ON_BN_CLICKED(IDC_CHOOSE_DLL, OnChooseDll) - ON_BN_CLICKED(IDC_RELOAD_DLL, OnReloadDll) - //}}AFX_MSG_MAP + //{{AFX_MSG_MAP(TestPlugInRunnerDlg) + ON_WM_PAINT() + ON_WM_QUERYDRAGICON() + ON_BN_CLICKED(IDC_CHOOSE_DLL, OnChooseDll) + ON_BN_CLICKED(IDC_RELOAD_DLL, OnReloadDll) + //}}AFX_MSG_MAP END_MESSAGE_MAP() ///////////////////////////////////////////////////////////////////////////// @@ -48,16 +51,17 @@ END_MESSAGE_MAP() BOOL TestPlugInRunnerDlg::OnInitDialog() { - TestRunnerDlg::OnInitDialog(); - - // Set the icon for this dialog. The framework does this automatically - // when the application's main window is not a dialog - SetIcon(m_hIcon, TRUE); // Set big icon - SetIcon(m_hIcon, FALSE); // Set small icon - - // TODO: Add extra initialization here - - return TRUE; // return TRUE unless you set the focus to a control + TestRunnerDlg::OnInitDialog(); + + // Set the icon for this dialog. The framework does this automatically + // when the application's main window is not a dialog + SetIcon(m_hIcon, TRUE); // Set big icon + SetIcon(m_hIcon, FALSE); // Set small icon + + // TODO: Add extra initialization here + loadPluginIfNesseccary(); + + return TRUE; // return TRUE unless you set the focus to a control } // If you add a minimize button to your dialog, you will need the code below @@ -66,34 +70,35 @@ BOOL TestPlugInRunnerDlg::OnInitDialog() void TestPlugInRunnerDlg::OnPaint() { - if (IsIconic()) - { - CPaintDC dc(this); // device context for painting - - SendMessage(WM_ICONERASEBKGND, (WPARAM) dc.GetSafeHdc(), 0); - - // Center icon in client rectangle - int cxIcon = GetSystemMetrics(SM_CXICON); - int cyIcon = GetSystemMetrics(SM_CYICON); - CRect rect; - GetClientRect(&rect); - int x = (rect.Width() - cxIcon + 1) / 2; - int y = (rect.Height() - cyIcon + 1) / 2; - - // Draw the icon - dc.DrawIcon(x, y, m_hIcon); - } - else - { - TestRunnerDlg::OnPaint(); - } + if (IsIconic()) + { + CPaintDC dc(this); // device context for painting + + SendMessage(WM_ICONERASEBKGND, (WPARAM) dc.GetSafeHdc(), 0); + + // Center icon in client rectangle + int cxIcon = GetSystemMetrics(SM_CXICON); + int cyIcon = GetSystemMetrics(SM_CYICON); + CRect rect; + GetClientRect(&rect); + int x = (rect.Width() - cxIcon + 1) / 2; + int y = (rect.Height() - cyIcon + 1) / 2; + + // Draw the icon + dc.DrawIcon(x, y, m_hIcon); + } + else + { + TestRunnerDlg::OnPaint(); + } } + // The system calls this to obtain the cursor to display while the user drags // the minimized window. HCURSOR TestPlugInRunnerDlg::OnQueryDragIcon() { - return (HCURSOR) m_hIcon; + return (HCURSOR) m_hIcon; } @@ -115,9 +120,7 @@ TestPlugInRunnerDlg::OnChooseDll() try { - TestPlugIn *plugIn = new TestPlugIn( std::string( dlg.GetPathName() ) ); - plugInModel().setPlugIn( plugIn ); - updateHistoryCombo(); + loadDll(std::string(dlg.GetPathName())); } catch ( TestPlugInException &e ) { @@ -129,5 +132,55 @@ TestPlugInRunnerDlg::OnChooseDll() void TestPlugInRunnerDlg::OnReloadDll() { + reset(); plugInModel().reloadPlugIn(); } + + +std::list<std::string> +TestPlugInRunnerDlg::getCommandLineArguments() +{ + int argc; + LPWSTR *argv = ::CommandLineToArgvW( ::GetCommandLineW(), &argc ); + + std::list<std::string> arguments; + for( int index = 0; index < argc; index++ ) + arguments.push_back( std::string( CString( argv[index] ) ) ); + + ::GlobalFree( argv ); + + return arguments; +} + + +void +TestPlugInRunnerDlg::loadPluginIfNesseccary() +{ + std::list<std::string> argv = getCommandLineArguments(); + std::list<std::string>::iterator iter = std::find( argv.begin(), + argv.end(), + std::string( "-testsuite" ) ); + + if ( iter == argv.end() ) + return; + + try + { + loadDll( *++iter ); + } + catch( std::exception &e ) + { + AfxMessageBox( e.what() ); + } +} + + +void +TestPlugInRunnerDlg::loadDll( std::string path ) +{ + TestPlugIn *plugIn = new TestPlugIn( path ); + plugInModel().setPlugIn( plugIn ); + + m_model->selectHistoryTest( plugInModel().rootTest() ); + updateHistoryCombo(); +} diff --git a/src/msvc6/testpluginrunner/TestPlugInRunnerDlg.h b/src/msvc6/testpluginrunner/TestPlugInRunnerDlg.h index af52c24..f2b979a 100644 --- a/src/msvc6/testpluginrunner/TestPlugInRunnerDlg.h +++ b/src/msvc6/testpluginrunner/TestPlugInRunnerDlg.h @@ -12,6 +12,8 @@ #include <TestRunnerDlg.h> #include <TestRunnerModel.h> #include "TestPlugInRunnerModel.h" +#include <list> +#include <string> ///////////////////////////////////////////////////////////////////////////// // TestPlugInRunnerDlg dialog @@ -20,35 +22,39 @@ class TestPlugInRunnerDlg : public TestRunnerDlg { // Construction public: - TestPlugInRunnerDlg( TestPlugInRunnerModel *model, + TestPlugInRunnerDlg( TestPlugInRunnerModel *model, CWnd* pParent = NULL); // Dialog Data - //{{AFX_DATA(TestPlugInRunnerDlg) - enum { IDD = IDD_TEST_PLUG_IN_RUNNER }; - //}}AFX_DATA + //{{AFX_DATA(TestPlugInRunnerDlg) + enum { IDD = IDD_TEST_PLUG_IN_RUNNER }; + //}}AFX_DATA - // ClassWizard generated virtual function overrides - //{{AFX_VIRTUAL(TestPlugInRunnerDlg) - protected: - virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support - //}}AFX_VIRTUAL + // ClassWizard generated virtual function overrides + //{{AFX_VIRTUAL(TestPlugInRunnerDlg) + protected: + virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support + //}}AFX_VIRTUAL // Implementation protected: - HICON m_hIcon; - - // Generated message map functions - //{{AFX_MSG(TestPlugInRunnerDlg) - virtual BOOL OnInitDialog(); - afx_msg void OnPaint(); - afx_msg HCURSOR OnQueryDragIcon(); - afx_msg void OnChooseDll(); - afx_msg void OnReloadDll(); - //}}AFX_MSG - DECLARE_MESSAGE_MAP(); + HICON m_hIcon; + + // Generated message map functions + //{{AFX_MSG(TestPlugInRunnerDlg) + virtual BOOL OnInitDialog(); + afx_msg void OnPaint(); + afx_msg HCURSOR OnQueryDragIcon(); + afx_msg void OnChooseDll(); + afx_msg void OnReloadDll(); + //}}AFX_MSG + DECLARE_MESSAGE_MAP(); private: TestPlugInRunnerModel &plugInModel(); + + static std::list<std::string> getCommandLineArguments(); + void loadPluginIfNesseccary(); + void loadDll( std::string path ); }; //{{AFX_INSERT_LOCATION}} diff --git a/src/msvc6/testpluginrunner/TestPlugInRunnerModel.cpp b/src/msvc6/testpluginrunner/TestPlugInRunnerModel.cpp index 93c0b13..ae0effe 100644 --- a/src/msvc6/testpluginrunner/TestPlugInRunnerModel.cpp +++ b/src/msvc6/testpluginrunner/TestPlugInRunnerModel.cpp @@ -37,7 +37,11 @@ TestPlugInRunnerModel::reloadPlugIn() { try { + CWaitCursor waitCursor; + m_history.clear(); setRootTest( m_plugIn->makeTest() ); + + loadHistory(); } catch (...) { diff --git a/src/msvc6/testrunner/MsDevCallerListCtrl.cpp b/src/msvc6/testrunner/MsDevCallerListCtrl.cpp index 117bc6b..0cf565e 100644 --- a/src/msvc6/testrunner/MsDevCallerListCtrl.cpp +++ b/src/msvc6/testrunner/MsDevCallerListCtrl.cpp @@ -23,10 +23,13 @@ MsDevCallerListCtrl::MsDevCallerListCtrl() : m_lineNumberSubItem( 3 ) , m_fileNameSubItem( 4 ) { + m_comInitialized = SUCCEEDED( CoInitialize(NULL) ); } MsDevCallerListCtrl::~MsDevCallerListCtrl() { + if ( m_comInitialized ) + CoUninitialize(); } diff --git a/src/msvc6/testrunner/MsDevCallerListCtrl.h b/src/msvc6/testrunner/MsDevCallerListCtrl.h index cc531e2..cf63edd 100644 --- a/src/msvc6/testrunner/MsDevCallerListCtrl.h +++ b/src/msvc6/testrunner/MsDevCallerListCtrl.h @@ -45,6 +45,7 @@ protected: private: int m_lineNumberSubItem; int m_fileNameSubItem; + bool m_comInitialized; }; ///////////////////////////////////////////////////////////////////////////// diff --git a/src/msvc6/testrunner/Resource.h b/src/msvc6/testrunner/Resource.h index b283858..8791272 100644 --- a/src/msvc6/testrunner/Resource.h +++ b/src/msvc6/testrunner/Resource.h @@ -27,6 +27,7 @@ #define IDC_BROWSE_TEST 1011 #define IDC_TREE_TEST 1012 #define IDC_CHECK_AUTORUN 1013 +#define IDC_RUNNING_TEST_CASE_LABEL 1016 #define ID_QUIT_APPLICATION 32771 // Next default values for new objects @@ -35,7 +36,7 @@ #ifndef APSTUDIO_READONLY_SYMBOLS #define _APS_NEXT_RESOURCE_VALUE 134 #define _APS_NEXT_COMMAND_VALUE 32772 -#define _APS_NEXT_CONTROL_VALUE 1016 +#define _APS_NEXT_CONTROL_VALUE 1017 #define _APS_NEXT_SYMED_VALUE 101 #endif #endif diff --git a/src/msvc6/testrunner/TestRunner.dsp b/src/msvc6/testrunner/TestRunner.dsp index 413b9eb..61aa46d 100644 --- a/src/msvc6/testrunner/TestRunner.dsp +++ b/src/msvc6/testrunner/TestRunner.dsp @@ -291,10 +291,6 @@ SOURCE=.\TestRunner.cpp # End Source File # Begin Source File -SOURCE=..\..\..\include\cppunitui\mfc\TestRunner.h -# End Source File -# Begin Source File - SOURCE=..\..\..\include\msvc6\testrunner\TestRunner.h # End Source File # Begin Source File diff --git a/src/msvc6/testrunner/TestRunner.rc b/src/msvc6/testrunner/TestRunner.rc index 1c08441..6d55684 100644 --- a/src/msvc6/testrunner/TestRunner.rc +++ b/src/msvc6/testrunner/TestRunner.rc @@ -118,7 +118,7 @@ BEGIN PUSHBUTTON "&Close",IDCANCEL,202,34,50,14 END -IDD_DIALOG_TESTRUNNER DIALOG DISCARDABLE 0, 0, 404, 214 +IDD_DIALOG_TESTRUNNER DIALOGEX 0, 0, 404, 214 STYLE WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_THICKFRAME CAPTION "TestRunner" @@ -133,7 +133,7 @@ BEGIN BS_AUTOCHECKBOX | BS_MULTILINE | WS_TABSTOP,348,73,49,19 PUSHBUTTON "&Stop",ID_STOP,347,177,50,14 PUSHBUTTON "&Close",IDOK,347,193,50,14 - LTEXT "Progress:",IDC_STATIC,7,38,49,9 + LTEXT "Progress:",IDC_STATIC,7,38,33,9 LTEXT "0",IDC_STATIC_RUNS,48,80,30,8 LTEXT "Failures:",IDC_STATIC,174,80,29,10 LTEXT "0",IDC_STATIC_FAILURES,212,80,19,8 @@ -144,6 +144,7 @@ BEGIN LTEXT "Errors:",IDC_STATIC,89,80,29,10 LTEXT "0",IDC_STATIC_ERRORS,127,80,19,8 LTEXT "Runs:",IDC_STATIC,7,80,29,10 + LTEXT "none",IDC_RUNNING_TEST_CASE_LABEL,43,39,166,9 END diff --git a/src/msvc6/testrunner/TestRunnerDlg.cpp b/src/msvc6/testrunner/TestRunnerDlg.cpp index 83ea7ed..979ce63 100644 --- a/src/msvc6/testrunner/TestRunnerDlg.cpp +++ b/src/msvc6/testrunner/TestRunnerDlg.cpp @@ -241,6 +241,9 @@ TestRunnerDlg::addListEntry( const CppUnit::TestFailure &failure ) void TestRunnerDlg::startTest( CppUnit::Test *test ) { + CWnd *runningTestCaseLabel = GetDlgItem(IDC_RUNNING_TEST_CASE_LABEL); + if ( runningTestCaseLabel ) + runningTestCaseLabel->SetWindowText( test->getName().c_str() ); } diff --git a/src/msvc6/testrunner/TestRunnerModel.h b/src/msvc6/testrunner/TestRunnerModel.h index b036911..056101b 100644 --- a/src/msvc6/testrunner/TestRunnerModel.h +++ b/src/msvc6/testrunner/TestRunnerModel.h @@ -68,7 +68,7 @@ private: /// Prevents the use of the copy operator. TestRunnerModel &operator =( const TestRunnerModel © ); -private: +protected: History m_history; CppUnit::Test *m_rootTest; |
