diff options
author | Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> | 2016-07-14 16:48:25 +0200 |
---|---|---|
committer | Lars Knoll <lars.knoll@qt.io> | 2016-08-08 09:48:38 +0000 |
commit | 22d1351ddea193f5c00d4ae12229358dea826c62 (patch) | |
tree | 11035ec483d22ebc0178ae63a4c0d40015bbe9a9 /tests/auto/tools/qmakelib/evaltest.cpp | |
parent | 6aa3ba0a0b91bc38eb7ff282ef2511964dd99080 (diff) |
print no message at all when no argument is supplied to error()
this is useful when an adequate message has already been emitted by
other means, like various built-ins do.
Change-Id: I092771f55969fad8b214204d666327664727c572
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'tests/auto/tools/qmakelib/evaltest.cpp')
-rw-r--r-- | tests/auto/tools/qmakelib/evaltest.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/tests/auto/tools/qmakelib/evaltest.cpp b/tests/auto/tools/qmakelib/evaltest.cpp index 21c1759b08..ffdf9294b8 100644 --- a/tests/auto/tools/qmakelib/evaltest.cpp +++ b/tests/auto/tools/qmakelib/evaltest.cpp @@ -2346,12 +2346,18 @@ void tst_qmakelib::addTestFunctions(const QString &qindir) << "Project WARNING: World, be warned!" << true; - QTest::newRow("error()") + QTest::newRow("error(message)") << "error('World, you FAIL!'): OK = 1\nOKE = 1" << "OK = UNDEF\nOKE = UNDEF" << "Project ERROR: World, you FAIL!" << false; + QTest::newRow("error(empty)") + << "error(): OK = 1\nOKE = 1" + << "OK = UNDEF\nOKE = UNDEF" + << "" + << false; + QTest::newRow("if(error())") << "if(error(\\'World, you FAIL!\\')): OK = 1\nOKE = 1" << "OK = UNDEF\nOKE = UNDEF" |