diff options
author | Oswald Buddenhagen <oswald.buddenhagen@nokia.com> | 2009-06-30 16:02:00 (GMT) |
---|---|---|
committer | Oswald Buddenhagen <oswald.buddenhagen@nokia.com> | 2009-06-30 16:02:00 (GMT) |
commit | 7e91986c352677d4c0456d30e1cb5fc3179e28c3 (patch) | |
tree | 7bbba8ba409b02f19a239936eb224fd39892b952 /tests/auto/linguist | |
parent | aa59008b92d4d1eb5b45352cac3408cc39086dba (diff) | |
download | Qt-7e91986c352677d4c0456d30e1cb5fc3179e28c3.zip Qt-7e91986c352677d4c0456d30e1cb5fc3179e28c3.tar.gz Qt-7e91986c352677d4c0456d30e1cb5fc3179e28c3.tar.bz2 |
add 4.6 specific modifications to linguist tools tests
Diffstat (limited to 'tests/auto/linguist')
7 files changed, 123 insertions, 2 deletions
diff --git a/tests/auto/linguist/lupdate/testdata/good/lacksqobject/expectedoutput.txt b/tests/auto/linguist/lupdate/testdata/good/lacksqobject/expectedoutput.txt index 8a0bd11..1a6cfeb 100644 --- a/tests/auto/linguist/lupdate/testdata/good/lacksqobject/expectedoutput.txt +++ b/tests/auto/linguist/lupdate/testdata/good/lacksqobject/expectedoutput.txt @@ -1,4 +1,8 @@ .*/lupdate/testdata/good/lacksqobject/main.cpp:17: Class 'B' lacks Q_OBJECT macro -.*/lupdate/testdata/good/lacksqobject/main.cpp:26: Class 'C' lacks Q_OBJECT macro + +.*/lupdate/testdata/good/lacksqobject/main.cpp:24: Class 'C' lacks Q_OBJECT macro + .*/lupdate/testdata/good/lacksqobject/main.cpp:37: Class 'nsB::B' lacks Q_OBJECT macro -.*/lupdate/testdata/good/lacksqobject/main.cpp:45: Class 'nsB::C' lacks Q_OBJECT macro + +.*/lupdate/testdata/good/lacksqobject/main.cpp:43: Class 'nsB::C' lacks Q_OBJECT macro + diff --git a/tests/auto/linguist/lupdate/testdata/good/parsecpp2/expectedoutput.txt b/tests/auto/linguist/lupdate/testdata/good/parsecpp2/expectedoutput.txt new file mode 100644 index 0000000..e3f7926 --- /dev/null +++ b/tests/auto/linguist/lupdate/testdata/good/parsecpp2/expectedoutput.txt @@ -0,0 +1,7 @@ +.*/lupdate/testdata/good/parsecpp2/main.cpp:10: Excess closing brace .* + +.*/lupdate/testdata/good/parsecpp2/main.cpp:14: Excess closing brace .* + +.*/lupdate/testdata/good/parsecpp2/main.cpp:20: Excess closing brace .* + +.*/lupdate/testdata/good/parsecpp2/main.cpp:24: Excess closing brace .* diff --git a/tests/auto/linguist/lupdate/testdata/good/parsecpp2/main.cpp b/tests/auto/linguist/lupdate/testdata/good/parsecpp2/main.cpp new file mode 100644 index 0000000..eb4a09b --- /dev/null +++ b/tests/auto/linguist/lupdate/testdata/good/parsecpp2/main.cpp @@ -0,0 +1,24 @@ +// IMPORTANT!!!! If you want to add testdata to this file, +// always add it to the end in order to not change the linenumbers of translations!!! + +// nothing here + +// sickness: multi-\ +line c++ comment } (with brace) + +#define This is a closing brace } which was ignored +} // complain here + +#define This is another \ + closing brace } which was ignored +} // complain here + +#define This is another /* comment in } define */\ + something /* comment ) + spanning {multiple} lines */ \ + closing brace } which was ignored +} // complain here + +#define This is another // comment in } define \ + something } comment +} // complain here diff --git a/tests/auto/linguist/lupdate/testdata/good/parsecpp2/main2.cpp b/tests/auto/linguist/lupdate/testdata/good/parsecpp2/main2.cpp new file mode 100644 index 0000000..1c72ac2 --- /dev/null +++ b/tests/auto/linguist/lupdate/testdata/good/parsecpp2/main2.cpp @@ -0,0 +1,28 @@ +// IMPORTANT!!!! If you want to add testdata to this file, +// always add it to the end in order to not change the linenumbers of translations!!! + +// nothing here + +// sickness: multi-\ +line c++ comment } (with brace) + +#define This is a closing brace } which was ignored +} // complain here + +#define This is another \ + closing brace } which was ignored +} // complain here + +#define This is another /* comment in } define */\ + something /* comment ) + spanning {multiple} lines */ \ + closing brace } which was ignored +} // complain here + +#define This is another // comment in } define \ + something } comment +} // complain here + +char somestring[] = "\ + continued\n\ + here and \"quoted\" to activate\n"; diff --git a/tests/auto/linguist/lupdate/testdata/good/parsecpp2/main3.cpp b/tests/auto/linguist/lupdate/testdata/good/parsecpp2/main3.cpp new file mode 100644 index 0000000..731d5cdf --- /dev/null +++ b/tests/auto/linguist/lupdate/testdata/good/parsecpp2/main3.cpp @@ -0,0 +1,42 @@ +// IMPORTANT!!!! If you want to add testdata to this file, +// always add it to the end in order to not change the linenumbers of translations!!! + +// nothing here + +// sickness: multi-\ +line c++ comment } (with brace) + +#define This is a closing brace } which was ignored +} // complain here + +#define This is another \ + closing brace } which was ignored +} // complain here + +#define This is another /* comment in } define */\ + something /* comment ) + spanning {multiple} lines */ \ + closing brace } which was ignored +} // complain here + +#define This is another // comment in } define \ + something } comment +} // complain here + +char somestring[] = "\ + continued\n\ + here and \"quoted\" to activate\n"; + + NSString *scriptSource = @"\ + on SetupNewMail(theRecipientAddress, theSubject, theContent, theAttachmentPath)\n\ + tell application \"Mail\" to activate\n\ + tell application \"Mail\"\n\ + set theMessage to make new outgoing message with properties {visible:true, subject:theSubject, content:theContent}\n\ + tell theMessage\n\ + make new to recipient at end of to recipients with properties {address:theRecipientAddress}\n\ + end tell\n\ + tell content of theMessage\n\ + make new attachment with properties {file name:theAttachmentPath} at after last paragraph\n\ + end tell\n\ + end tell\n\ + end SetupNewMail\n"; diff --git a/tests/auto/linguist/lupdate/testdata/good/parsecpp2/project.pro b/tests/auto/linguist/lupdate/testdata/good/parsecpp2/project.pro new file mode 100644 index 0000000..7547a8d --- /dev/null +++ b/tests/auto/linguist/lupdate/testdata/good/parsecpp2/project.pro @@ -0,0 +1,12 @@ +TEMPLATE = app +LANGUAGE = C++ + +SOURCES = main.cpp + +TRANSLATIONS += project.ts + +exists( $$TRANSLATIONS ) { + win32: system(del $$TRANSLATIONS) + unix: system(rm $$TRANSLATIONS) +} + diff --git a/tests/auto/linguist/lupdate/testdata/good/parsecpp2/project.ts.result b/tests/auto/linguist/lupdate/testdata/good/parsecpp2/project.ts.result new file mode 100644 index 0000000..07a7469 --- /dev/null +++ b/tests/auto/linguist/lupdate/testdata/good/parsecpp2/project.ts.result @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.0"> +</TS> |