I am trying to use cppunit to test an application originally developed in Visual Studio 6 and later upgraded to Visual Studio 2005.
When I debug my application I get the following assertion error.
Debug Assertion Failed!
File: f :\rtm\vctools\vc7libs\ship\atlmfc\include\afxwin1.inl
Line:24
_AFXWIN_INLINE HINSTANCE AFXAPI AfxGetResourceHandle()
{ ASSERT(afxCurrentResourceHandle != NULL); <============= this line
Call stack:
mfc80d.dll!AfxGetResourceHandle() Line 24 + 0x1e bytes C++
mfc80d.dll!CDialog::DoModal() Line 492 + 0x5 bytes C++
testrunnerd.dll!CppUnit::MfcTestRunner::run() Line 41 C++
In the CDialog::DoModal() method parameter m_lpszTemplateName has the right resource name
("CPP_UNIT_TEST_RUNNER_IDD_DIALOG_TESTRUNNER"), the m_lpDialogTemplate and m_lpDialogTemplate are both NULL when I
call HINSTANCE hInst = AfxGetResourceHandle(); where things breaks.
I have used mfctestrunner successfully in other projects(other MFC applications in VS 2005).
Please help me.
Thanks
Smi007
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
Anyone please help me..
I am trying to use cppunit to test an application originally developed in Visual Studio 6 and later upgraded to Visual Studio 2005.
When I debug my application I get the following assertion error.
Debug Assertion Failed!
File: f :\rtm\vctools\vc7libs\ship\atlmfc\include\afxwin1.inl
Line:24
_AFXWIN_INLINE HINSTANCE AFXAPI AfxGetResourceHandle()
{ ASSERT(afxCurrentResourceHandle != NULL); <============= this line
Call stack:
mfc80d.dll!AfxGetResourceHandle() Line 24 + 0x1e bytes C++
mfc80d.dll!CDialog::DoModal() Line 492 + 0x5 bytes C++
testrunnerd.dll!CppUnit::MfcTestRunner::run() Line 41 C++
In the CDialog::DoModal() method parameter m_lpszTemplateName has the right resource name
("CPP_UNIT_TEST_RUNNER_IDD_DIALOG_TESTRUNNER"), the m_lpDialogTemplate and m_lpDialogTemplate are both NULL when I
call HINSTANCE hInst = AfxGetResourceHandle(); where things breaks.
I have used mfctestrunner successfully in other projects(other MFC applications in VS 2005).
Please help me.
Thanks
Smi007