diff options
author | Oswald Buddenhagen <oswald.buddenhagen@digia.com> | 2013-08-01 14:41:08 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-08-06 09:30:39 +0200 |
commit | 20ce1bdb3dd7b1b8868145bf8aec6a9bb788903b (patch) | |
tree | 067ea47e0cc53568eafaf3ad1354855cfeda570b /tests | |
parent | a4e8dca0c3665a26ff5e7dffada97aeab86dd1a5 (diff) |
update all data of existing messages in extend()
when the message identifier (msgid or context/source/disambiguation)
appears in multiple places, the remaining meta data may be inconsistent
between the occurrences. we need to handle partial data on one hand, and
contradicting data on the other.
Task-number: QTBUG-29131
Task-number: QTBUG-32725
Change-Id: I1ed08e42e266b0b5f014400c137abbcec9ffb93d
Reviewed-by: hjk <hjk121@nokiamail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/linguist/lupdate/testdata/good/multiple_locations/main.cpp | 17 | ||||
-rw-r--r-- | tests/auto/linguist/lupdate/testdata/good/multiple_locations/project.ts.result | 23 |
2 files changed, 40 insertions, 0 deletions
diff --git a/tests/auto/linguist/lupdate/testdata/good/multiple_locations/main.cpp b/tests/auto/linguist/lupdate/testdata/good/multiple_locations/main.cpp index d06e8b2ca..fa01f9d16 100644 --- a/tests/auto/linguist/lupdate/testdata/good/multiple_locations/main.cpp +++ b/tests/auto/linguist/lupdate/testdata/good/multiple_locations/main.cpp @@ -47,7 +47,24 @@ QT_TRANSLATE_NOOP("context", "just a message"); +//: commented +qtTrId("lollipop"); +//% "this is the source text" +//~ meta so-meta +//: even more commented +qtTrId("lollipop"); +//% "this is contradicting source text" +qtTrId("lollipop"); +//~ meta too-much-meta +qtTrId("lollipop"); + + +//~ meta so-meta +QObject::tr("another message", "here with a lot of noise in the comment so it is long enough"); + +//~ meta too-much-meta +QObject::tr("another message", "here with a lot of noise in the comment so it is long enough"); diff --git a/tests/auto/linguist/lupdate/testdata/good/multiple_locations/project.ts.result b/tests/auto/linguist/lupdate/testdata/good/multiple_locations/project.ts.result index a7ae15520..b0a171757 100644 --- a/tests/auto/linguist/lupdate/testdata/good/multiple_locations/project.ts.result +++ b/tests/auto/linguist/lupdate/testdata/good/multiple_locations/project.ts.result @@ -2,6 +2,29 @@ <!DOCTYPE TS> <TS version="2.0"> <context> + <name></name> + <message id="lollipop"> + <location filename="main.cpp" line="51"/> + <location filename="main.cpp" line="56"/> + <source>this is the source text</source> + <extracomment>commented +---------- +even more commented</extracomment> + <translation type="unfinished"></translation> + <extra-meta>so-meta</extra-meta> + </message> +</context> +<context> + <name>QObject</name> + <message> + <location filename="main.cpp" line="67"/> + <source>another message</source> + <comment>here with a lot of noise in the comment so it is long enough</comment> + <translation type="unfinished"></translation> + <extra-meta>so-meta</extra-meta> + </message> +</context> +<context> <name>context</name> <message> <location filename="finddialog.cpp" line="42"/> |