[mapguide-commits] r8144 - branches/2.6/MgDev/Server/src/UnitTesting
svn_mapguide at osgeo.org
svn_mapguide at osgeo.org
Wed May 21 21:25:19 PDT 2014
Author: jng
Date: 2014-05-21 21:25:19 -0700 (Wed, 21 May 2014)
New Revision: 8144
Modified:
branches/2.6/MgDev/Server/src/UnitTesting/TestFeatureService.cpp
Log:
Suppress any messages boxes due to loading dlls with unmet dependencies (ie. A FDO provider) when running Feature Service tests.
Modified: branches/2.6/MgDev/Server/src/UnitTesting/TestFeatureService.cpp
===================================================================
--- branches/2.6/MgDev/Server/src/UnitTesting/TestFeatureService.cpp 2014-05-21 08:20:37 UTC (rev 8143)
+++ branches/2.6/MgDev/Server/src/UnitTesting/TestFeatureService.cpp 2014-05-22 04:25:19 UTC (rev 8144)
@@ -44,6 +44,19 @@
{
ACE_DEBUG((LM_INFO, ACE_TEXT("\nRunning Feature Service tests.\n")));
+#ifdef _WIN32
+ //If the FDO we're using has a full providers.xml and we haven't met the dependencies
+ //of some providers (eg. OCI.dll for King.Oracle), then it's going to show a message box
+ //in our face about this that has to be manually dismissed. Not something you want to have
+ //happen when trying to run tests in an automated fashion. This test suite only covers the
+ //SDF, SHP and SQLite providers so having such message boxes show up is intrusive.
+ //
+ //This call will suppress such message boxes when loading dlls with unmet depdendencies. It's
+ //okay to do this here because mgserver.exe would not be running as a service or long-running process
+ //when running its test suite, so this will only take effect for the duration of the test run
+ SetErrorMode(SEM_FAILCRITICALERRORS);
+#endif
+
try
{
#ifdef _DEBUG
More information about the mapguide-commits
mailing list