Loading

Paste #p9rio9e19

  1. diff --git a/qt5/tests/CMakeLists.txt b/qt5/tests/CMakeLists.txt
  2. index 7fda2687..8d18e5ff 100644
  3. --- a/qt5/tests/CMakeLists.txt
  4. +++ b/qt5/tests/CMakeLists.txt
  5. @@ -35,7 +35,7 @@ macro(QT5_ADD_QTEST exe source)
  6.        ${source}
  7.      )
  8.      poppler_add_unittest(${exe} BUILD_QT5_TESTS ${${test_name}_SOURCES})
  9. -    target_link_libraries(${exe} poppler-qt5 ${Qt5Widgets_LIBRARIES} ${Qt5Test_LIBRARIES} ${Qt5Core_LIBRARIES} ${Qt5Gui_LIBRARIES})
  10. +    target_link_libraries(${exe} poppler-qt5 ${Qt5Widgets_LIBRARIES} ${Qt5Test_LIBRARIES} ${Qt5Core_LIBRARIES} ${Qt5Gui_LIBRARIES} poppler-cpp)
  11.      if(MSVC)
  12.        target_link_libraries(${exe} poppler ${poppler_LIBS})
  13.      endif()
  14. diff --git a/qt5/tests/check_strings.cpp b/qt5/tests/check_strings.cpp
  15. index 583617aa..79c7d3ff 100644
  16. --- a/qt5/tests/check_strings.cpp
  17. +++ b/qt5/tests/check_strings.cpp
  18. @@ -22,6 +22,7 @@
  19.  #include <poppler-private.h>
  20.  
  21.  #include <GlobalParams.h>
  22. +#include <../cpp/poppler-private.h>
  23.  
  24.  Q_DECLARE_METATYPE(GooString*)
  25.  Q_DECLARE_METATYPE(Unicode*)
  26. @@ -170,7 +171,10 @@ void TestStrings::check_UnicodeParsedString()
  27.      QFETCH(GooString*, string);
  28.      QFETCH(QString, result);
  29.  
  30. +    poppler::byte_array ba = poppler::detail::unicode_GooString_to_ustring(string).to_utf8();
  31. +
  32.      QCOMPARE(Poppler::UnicodeParsedString(string), result);
  33. +    QCOMPARE(QString::fromUtf8(ba.data(), ba.size()), result);
  34.  }
  35.  
  36.  void TestStrings::check_QStringToUnicodeGooString_data()

Comments