From 59dbb1b7e737713fc650c25a20967ec26cc3ff3d Mon Sep 17 00:00:00 2001 From: Kim Motoyoshi Kalland Date: Wed, 16 Sep 2009 16:00:19 +0200 Subject: Fixed the qkeysequence::translated autotest. The test failed because it tried to open a .qm file which didn't exist in Qt's translations directory. Fixed by running lrelease on the .ts file and copying the resulting .qm into the test directory. Reviewed-by: Trond --- tests/auto/qkeysequence/qkeysequence.pro | 4 +--- tests/auto/qkeysequence/qkeysequence.qrc | 6 ++++++ tests/auto/qkeysequence/qt_de.qm | Bin 0 -> 186240 bytes tests/auto/qkeysequence/tst_qkeysequence.cpp | 4 ++-- 4 files changed, 9 insertions(+), 5 deletions(-) create mode 100644 tests/auto/qkeysequence/qkeysequence.qrc create mode 100644 tests/auto/qkeysequence/qt_de.qm diff --git a/tests/auto/qkeysequence/qkeysequence.pro b/tests/auto/qkeysequence/qkeysequence.pro index 6566340..bd85402 100644 --- a/tests/auto/qkeysequence/qkeysequence.pro +++ b/tests/auto/qkeysequence/qkeysequence.pro @@ -1,6 +1,4 @@ load(qttest_p4) SOURCES += tst_qkeysequence.cpp -TRANSLATIONS += keys_de.ts - - +RESOURCES += qkeysequence.qrc \ No newline at end of file diff --git a/tests/auto/qkeysequence/qkeysequence.qrc b/tests/auto/qkeysequence/qkeysequence.qrc new file mode 100644 index 0000000..e224faa --- /dev/null +++ b/tests/auto/qkeysequence/qkeysequence.qrc @@ -0,0 +1,6 @@ + + + keys_de.qm + qt_de.qm + + diff --git a/tests/auto/qkeysequence/qt_de.qm b/tests/auto/qkeysequence/qt_de.qm new file mode 100644 index 0000000..595e4d7 Binary files /dev/null and b/tests/auto/qkeysequence/qt_de.qm differ diff --git a/tests/auto/qkeysequence/tst_qkeysequence.cpp b/tests/auto/qkeysequence/tst_qkeysequence.cpp index 9da0671..868f843 100644 --- a/tests/auto/qkeysequence/tst_qkeysequence.cpp +++ b/tests/auto/qkeysequence/tst_qkeysequence.cpp @@ -166,9 +166,9 @@ tst_QKeySequence::~tst_QKeySequence() void tst_QKeySequence::initTestCase() { ourTranslator = new QTranslator(this); - ourTranslator->load(QLatin1String("keys_de"), "."); + ourTranslator->load(":/keys_de"); qtTranslator = new QTranslator(this); - qtTranslator->load(QLatin1String("qt_de"), QLibraryInfo::location(QLibraryInfo::TranslationsPath)); + qtTranslator->load(":/qt_de"); } void tst_QKeySequence::operatorQString_data() -- cgit v0.12