summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@digia.com>2012-11-19 12:13:28 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2012-11-20 18:57:54 +0100
commit2a290c70114ed841ed6f60a6997a596688fb6cc4 (patch)
tree6847caaf36629afb8e15e85290491168b2beb9ff /tests
parent57c2475ddc6c78633f0c14b2b154a5afbca7d633 (diff)
downloadqttools-2a290c70114ed841ed6f60a6997a596688fb6cc4.tar.gz
add support for TR_EXCLUDE
this is necessary for excluding 3rd party code, etc. Change-Id: I2d32b6014741178bb8a62d29185241c90488754d Reviewed-by: hjk <qthjk@ovi.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/linguist/lupdate/testdata/good/parsecpp/excluded.cpp45
-rw-r--r--tests/auto/linguist/lupdate/testdata/good/parsecpp/project.pro3
2 files changed, 48 insertions, 0 deletions
diff --git a/tests/auto/linguist/lupdate/testdata/good/parsecpp/excluded.cpp b/tests/auto/linguist/lupdate/testdata/good/parsecpp/excluded.cpp
new file mode 100644
index 000000000..1f21ad4e0
--- /dev/null
+++ b/tests/auto/linguist/lupdate/testdata/good/parsecpp/excluded.cpp
@@ -0,0 +1,45 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+int main(char **argv, int argc)
+{
+ QString fake = QApplication::tr("fake", "This message will not be collected");
+}
diff --git a/tests/auto/linguist/lupdate/testdata/good/parsecpp/project.pro b/tests/auto/linguist/lupdate/testdata/good/parsecpp/project.pro
index 37df00f40..d0dd914d4 100644
--- a/tests/auto/linguist/lupdate/testdata/good/parsecpp/project.pro
+++ b/tests/auto/linguist/lupdate/testdata/good/parsecpp/project.pro
@@ -1,5 +1,8 @@
SOURCES += main.cpp
SOURCES += finddialog.cpp
+SOURCES += excluded.cpp
+
+TR_EXCLUDE = $$PWD/excluded.*
TRANSLATIONS = project.ts
DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0