diff options
Diffstat (limited to 'Tests')
-rw-r--r-- | Tests/CMakeLists.txt | 16 | ||||
-rw-r--r-- | Tests/UseWX/CMakeLists.txt | 8 | ||||
-rw-r--r-- | Tests/UseWX/WX.cxx | 82 |
3 files changed, 0 insertions, 106 deletions
diff --git a/Tests/CMakeLists.txt b/Tests/CMakeLists.txt index a2cfa20..c7e6715 100644 --- a/Tests/CMakeLists.txt +++ b/Tests/CMakeLists.txt @@ -1198,22 +1198,6 @@ ${CMake_BINARY_DIR}/bin/cmake -DVERSION=CVS -P ${CMake_SOURCE_DIR}/Utilities/Rel ENDIF(CMAKE_TEST_GENERATOR MATCHES "Makefiles" OR CMAKE_TEST_GENERATOR MATCHES "KDevelop") - IF(BUILD_WXDialog AND wxWidgets_CONFIG_EXECUTABLE) - # Will be set if the WX gui is on - ADD_TEST(UseWX ${CMAKE_CTEST_COMMAND} - --build-and-test - "${CMake_SOURCE_DIR}/Tests/UseWX" - "${CMake_BINARY_DIR}/Tests/UseWX" - --build-generator ${CMAKE_TEST_GENERATOR} - --build-makeprogram ${CMAKE_TEST_MAKEPROGRAM} - --build-exe-dir ${CMake_BINARY_DIR}/Tests/UseWX - --build-project UsewxWidgets - --build-options -DwxWidgets_CONFIG_EXECUTABLE=${wxWidgets_CONFIG_EXECUTABLE} - --test-command UseWX - ) - LIST(APPEND TEST_BUILD_DIRS "${CMake_BINARY_DIR}/Tests/UseWX") - ENDIF(BUILD_WXDialog AND wxWidgets_CONFIG_EXECUTABLE) - IF(UNIX) STRING(COMPARE EQUAL "${CMAKE_INSTALL_PREFIX}" "${CMake_BINARY_DIR}/Tests/TestShellInstall/Prefix" PREFIX_IS_FOR_TEST) diff --git a/Tests/UseWX/CMakeLists.txt b/Tests/UseWX/CMakeLists.txt deleted file mode 100644 index 8638a08..0000000 --- a/Tests/UseWX/CMakeLists.txt +++ /dev/null @@ -1,8 +0,0 @@ -cmake_minimum_required (VERSION 2.6) -PROJECT (UsewxWidgets) - -FIND_PACKAGE(wxWidgets REQUIRED) -INCLUDE( ${wxWidgets_USE_FILE} ) - -ADD_EXECUTABLE (UseWX WIN32 WX.cxx) -TARGET_LINK_LIBRARIES(UseWX ${wxWidgets_LIBRARIES} ) diff --git a/Tests/UseWX/WX.cxx b/Tests/UseWX/WX.cxx deleted file mode 100644 index d463127..0000000 --- a/Tests/UseWX/WX.cxx +++ /dev/null @@ -1,82 +0,0 @@ -//For wx -#include <wx/app.h> -#include <wx/dir.h> - -static void TestDirEnumHelper(wxDir& dir, - int flags = wxDIR_DEFAULT, - const wxString& filespec = wxEmptyString) -{ - wxString filename; - - if ( !dir.IsOpened() ) - return; - - bool cont = dir.GetFirst(&filename, filespec, flags); - while ( cont ) - { - wxPrintf(_T("\t%s\n"), filename.c_str()); - - cont = dir.GetNext(&filename); - } - - wxPuts(_T("")); -} - - -//---------------------------------------------------------------------------- -// MyApp -//---------------------------------------------------------------------------- - -class MyApp: public wxApp -{ -public: - MyApp(); - - bool OnInit(); - int MainLoop(); -}; - - -IMPLEMENT_APP(MyApp) - -MyApp::MyApp() -{ -} - -bool MyApp::OnInit() -{ - //test a directory that exist: - wxDir dir(wxT(".")); //wxDir dir("/tmp"); - TestDirEnumHelper(dir, wxDIR_DEFAULT | wxDIR_DOTDOT); - - //Testing if link to wx debug library -#ifdef __WXDEBUG__ - printf("If you read this you're in __WXDEBUG__ debug mode.\n"); -#endif //__WXDEBUG__ - -#ifdef _DEBUG - printf("If you read this then _DEBUG is defined.\n"); -#endif //_DEBUG - - wxChar ch = wxT('*'); - wxString s = wxT("Hello, world!"); - int len = s.Len(); - printf("Length of string is: %d\n", len); - - //Force testing of Unicode mode -#ifdef __UNICODE__ - wprintf(L"Unicode: %s \n", s.c_str()); - wprintf(:"Char: %c\n", ch); -#else - printf("ANSI: %s \n", s.c_str()); - printf("Char: %c\n", ch); -#endif //__UNICODE__ - - //return immediately - return TRUE; -} - -int MyApp::MainLoop() -{ - return 0; -} |